8000
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d334b3d commit 3d63ae6Copy full SHA for 3d63ae6
packages/vite/src/node/plugins/css.ts
@@ -769,11 +769,15 @@ export function cssPostPlugin(config: ResolvedConfig): Plugin {
769
// chunks instead.
770
chunk.imports = chunk.imports.filter((file) => {
771
if (pureCssChunkNames.includes(file)) {
772
- const { importedCss } = (bundle[file] as OutputChunk)
773
- .viteMetadata!
+ const { importedCss, importedAssets } = (
+ bundle[file] as OutputChunk
774
+ ).viteMetadata!
775
importedCss.forEach((file) =>
776
chunk.viteMetadata!.importedCss.add(file),
777
)
778
+ importedAssets.forEach((file) =>
779
+ chunk.viteMetadata!.importedAssets.add(file),
780
+ )
781
return false
782
}
783
return true
0 commit comments