fix(nuxt3): always generate / route (#4421)

This commit is contained in:
pooya parsa 2022-04-19 10:17:41 +02:00 committed by GitHub
parent 0b8eeaf40f
commit ce38dcba1c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -52,7 +52,7 @@ export async function initNitro (nuxt: Nuxt) {
prerender: {
crawlLinks: nuxt.options._generate ? nuxt.options.generate.crawler : false,
routes: []
.concat(nuxt.options.generate.routes)
.concat(nuxt.options._generate ? ['/', ...nuxt.options.generate.routes] : [])
.concat(nuxt.options.ssr === false ? ['/', '/200', '/404'] : [])
},
externals: {