diff --git a/packages/nuxt/src/components/module.ts b/packages/nuxt/src/components/module.ts index 67769f6271..5663b05ac5 100644 --- a/packages/nuxt/src/components/module.ts +++ b/packages/nuxt/src/components/module.ts @@ -145,7 +145,7 @@ export default defineNuxtModule({ const sourceFiles = getComponents().filter(c => c.global).map(c => relative(nuxt.options.srcDir, c.filePath)) for (const chunkId in manifest) { - const chunk = manifest[chunkId] + const chunk = manifest[chunkId]! if (chunk.isEntry) { chunk.dynamicImports = chunk.dynamicImports?.filter(i => !sourceFiles.includes(i))