We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 98eb591 commit 14fee0cCopy full SHA for 14fee0c
1 file changed
remark/rehype-link-transformer.js
@@ -9,7 +9,7 @@ const rehypeLinkTransformer = () => (tree, vfile) => {
9
if (node.tagName === "a") {
10
const href = url.parse(node.properties.href);
11
if (href.hostname === null && href.pathname?.endsWith(".md") && existsSync(vfile.history[0])) {
12
- href.pathname = basename(href.pathname).replace(/.md$/, ".html");
+ href.pathname = basename(href.pathname).replace(/\.md$/, ".html");
13
node.properties.href = url.format(href);
14
}
15
0 commit comments