Skip to content

Commit e097f88

Browse files
committed
fix: homepage link
1 parent 033be4f commit e097f88

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

src/core/render/compiler.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,7 @@ export class Compiler {
211211
!_self.matchNotCompileLink(href) &&
212212
!config.ignore
213213
) {
214-
if (href === _self.config.homepage) href = '/'
214+
if (href === _self.config.homepage) href = 'README'
215215
href = router.toURL(href, null, router.getCurrentPath())
216216
} else {
217217
attrs += ` target="${linkTarget}"`

src/core/router/history/base.js

+1-3
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,7 @@ export class History {
3535
return this.config.basePath
3636
}
3737

38-
getFile (path, isRelative) {
39-
path = path || this.getCurrentPath()
40-
38+
getFile (path = this.getCurrentPath(), isRelative) {
4139
const { config } = this
4240
const base = this.getBasePath()
4341
const ext = typeof config.ext !== 'string' ? '.md' : config.ext

0 commit comments

Comments
 (0)