fix(build): consider base when checking actual pathname (#1858)

pull/1862/head
Divyansh Singh 2 years ago committed by GitHub
parent 2a9ee9de1b
commit cf8ad1a291
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -90,7 +90,7 @@ export function createRouter(
if (inBrowser) {
nextTick(() => {
let actualPathname =
'/' +
siteDataRef.value.base +
__pageData.relativePath.replace(/(?:(^|\/)index)?\.md$/, '$1')
if (!siteDataRef.value.cleanUrls && !actualPathname.endsWith('/')) {
actualPathname += '.html'

Loading…
Cancel
Save