mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-29 09:02:03 +00:00
fix(nuxt): use test
/dev
as manifest buildId when appropriate (#23512)
This commit is contained in:
parent
45c1e7f51f
commit
861d49e79f
@ -213,7 +213,8 @@ export async function initNitro (nuxt: Nuxt & { _nitro?: Nitro }) {
|
|||||||
// Add app manifest handler and prerender configuration
|
// Add app manifest handler and prerender configuration
|
||||||
if (nuxt.options.experimental.appManifest) {
|
if (nuxt.options.experimental.appManifest) {
|
||||||
// @ts-expect-error untyped nuxt property
|
// @ts-expect-error untyped nuxt property
|
||||||
const buildId = nuxt.options.appConfig.nuxt!.buildId ||= randomUUID()
|
const buildId = nuxt.options.appConfig.nuxt!.buildId ||=
|
||||||
|
(nuxt.options.test ? 'test' : nuxt.options.dev ? 'dev' : randomUUID())
|
||||||
const buildTimestamp = Date.now()
|
const buildTimestamp = Date.now()
|
||||||
|
|
||||||
const manifestPrefix = joinURL(nuxt.options.app.buildAssetsDir, 'builds')
|
const manifestPrefix = joinURL(nuxt.options.app.buildAssetsDir, 'builds')
|
||||||
|
@ -7,17 +7,6 @@ export default defineVitestConfig({
|
|||||||
},
|
},
|
||||||
test: {
|
test: {
|
||||||
dir: './test/nuxt',
|
dir: './test/nuxt',
|
||||||
environment: 'nuxt',
|
environment: 'nuxt'
|
||||||
environmentOptions: {
|
|
||||||
nuxt: {
|
|
||||||
overrides: {
|
|
||||||
appConfig: {
|
|
||||||
nuxt: {
|
|
||||||
buildId: 'test'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
Loading…
Reference in New Issue
Block a user