add optional current route param to toURL and use it to properly compose local anchor links
This commit is contained in:
parent
fbc75bdb95
commit
a706203879
2 changed files with 5 additions and 4 deletions
|
|
@ -82,7 +82,7 @@ renderer.code = function (code, lang = '') {
|
|||
renderer.link = function (href, title, text) {
|
||||
let blank = ''
|
||||
if (!/:|(\/{2})/.test(href)) {
|
||||
href = toURL(href)
|
||||
href = toURL(href, null, currentPath)
|
||||
} else {
|
||||
blank = ' target="_blank"'
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue