Skip to content

Commit

Permalink
fix: fix same page hash links with encoded chars
Browse files Browse the repository at this point in the history
close #1749
  • Loading branch information
yyx990803 committed Mar 10, 2023
1 parent 868a9ff commit e05a3f2
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/node/markdown/plugins/link.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ export const linkPlugin = (
!/\.(?!html|md)\w+($|\?)/i.test(url)
) {
normalizeHref(hrefAttr, env)
} else if (url.startsWith('#')) {
hrefAttr[1] = decodeURI(hrefAttr[1])
}

// append base to internal (non-relative) urls
Expand Down

0 comments on commit e05a3f2

Please sign in to comment.