fix(nitro): emit chunk names without # (#477)

This commit is contained in:
Daniel Roe 2021-09-05 21:48:38 +01:00 committed by GitHub
parent 0c50af9fd5
commit de57626a7a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -89,6 +89,9 @@ export const getRollupConfig = (nitroContext: NitroContext) => {
} else if (lastModule.includes('assets')) {
prefix = 'assets'
}
if (chunkInfo.name.includes('#')) {
return join('chunks', prefix, chunkInfo.name.replace(/#/g, '-') + '.mjs')
}
return join('chunks', prefix, '[name].mjs')
},
inlineDynamicImports: nitroContext.inlineDynamicImports,