chore: override experiments unexpectedly

Signed-off-by: JounQin <admin@1stg.me>
This commit is contained in:
JounQin
2024-08-14 19:00:43 +08:00
parent 4e64019790
commit 551abf6d55
+6 -7
View File
@@ -424,7 +424,12 @@ export async function createConfig(
: {}),
},
experiments: {
lazyCompilation: yn(process.env.EXPERIMENTAL_LAZY_COMPILATION),
lazyCompilation:
!useRspack && yn(process.env.EXPERIMENTAL_LAZY_COMPILATION),
...(useRspack && {
// We're still using `style-loader` for custom `insert` option
css: false,
}),
},
plugins,
...(withCache && {
@@ -435,12 +440,6 @@ export async function createConfig(
},
},
}),
...(useRspack && {
// We're still using `style-loader` for custom `insert` option
experiments: {
css: false,
},
}),
};
}