mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-11 08:33:53 +00:00
fix(vue-app): use correct $config
for finding basePath (#9706)
This commit is contained in:
parent
0145578493
commit
3c10f176e6
@ -58,7 +58,7 @@ const createNext = ssrContext => (opts) => {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
let fullPath = withQuery(opts.path, opts.query)
|
let fullPath = withQuery(opts.path, opts.query)
|
||||||
const $config = ssrContext.runtimeConfig || {}
|
const $config = ssrContext.nuxt.config || {}
|
||||||
const routerBase = ($config._app && $config._app.basePath) || '<%= router.base %>'
|
const routerBase = ($config._app && $config._app.basePath) || '<%= router.base %>'
|
||||||
if (!fullPath.startsWith('http') && (routerBase !== '/' && !fullPath.startsWith(routerBase))) {
|
if (!fullPath.startsWith('http') && (routerBase !== '/' && !fullPath.startsWith(routerBase))) {
|
||||||
fullPath = joinURL(routerBase, fullPath)
|
fullPath = joinURL(routerBase, fullPath)
|
||||||
|
Loading…
Reference in New Issue
Block a user