Skip to content

Commit aabc106

Browse files
committed
Only rewrite external links. Fixes #419
1 parent a5e697a commit aabc106

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

default-theme/lib/format_markdown.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ function getHref(paths) {
1515

1616
function rerouteLinks(ast) {
1717
visit(ast, 'link', function (node) {
18-
if (node.jsdoc) {
18+
if (node.jsdoc && !node.url.match(/^(http|https|\.)/)) {
1919
node.url = '#' + node.url;
2020
}
2121
});

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,11 +33,11 @@
3333
"micromatch": "^2.1.6",
3434
"mime": "^1.3.4",
3535
"module-deps-sortable": "4.0.6",
36-
"parse-filepath": "^1.0.1",
36+
"parse-filepath": "^0.6.3",
3737
"remark": "^4.1.2",
3838
"remark-html": "3.0.0",
3939
"remark-toc": "^3.0.0",
40-
"remote-origin-url": "0.5.1",
40+
"remote-origin-url": "0.4.0",
4141
"resolve": "^1.1.6",
4242
"slugg": "^1.0.0",
4343
"stream-array": "^1.1.0",

0 commit comments

Comments
 (0)