diff --git a/rsbuild/vanilla-extract/rsbuild.config.ts b/rsbuild/vanilla-extract/rsbuild.config.ts index c13640f1c..f7f9bd189 100644 --- a/rsbuild/vanilla-extract/rsbuild.config.ts +++ b/rsbuild/vanilla-extract/rsbuild.config.ts @@ -10,6 +10,21 @@ export default defineConfig({ }, }), ], + performance: { + chunkSplit: { + override: { + cacheGroups: { + vanillaCss: { + minSize: 0, + chunks: 'all', + test: /@vanilla-extract\/webpack-plugin/, + priority: 1000, + name: process.env.NODE_ENV === 'development' && 'vanilla-extract', + }, + }, + }, + }, + }, tools: { rspack: { plugins: [new VanillaExtractPlugin()],