fix: highlight homepage link, fixed #304
This commit is contained in:
parent
85428ef49e
commit
f960c196bf
1 changed files with 1 additions and 0 deletions
|
|
@ -187,6 +187,7 @@ export class Compiler {
|
||||||
!_self.matchNotCompileLink(href) &&
|
!_self.matchNotCompileLink(href) &&
|
||||||
!config.ignore
|
!config.ignore
|
||||||
) {
|
) {
|
||||||
|
if (href === _self.config.homepage) href = '/'
|
||||||
href = router.toURL(href, null, router.getCurrentPath())
|
href = router.toURL(href, null, router.getCurrentPath())
|
||||||
} else {
|
} else {
|
||||||
attrs += ` target="${linkTarget}"`
|
attrs += ` target="${linkTarget}"`
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue