hotfix: disable extract-css-chunks-webpack-plugin in dev mode (#4888)

This commit is contained in:
Xin Du (Clark) 2019-01-29 20:29:21 +00:00 committed by Pooya Parsa
parent 96bab9f09c
commit 928a230f91

View File

@ -291,6 +291,10 @@ export function getNuxtConfig(_options) {
options.build.optimization.minimize = !options.dev options.build.optimization.minimize = !options.dev
} }
if (options.dev) {
options.build.extractCSS = false
}
// Enable optimizeCSS only when extractCSS is enabled // Enable optimizeCSS only when extractCSS is enabled
if (options.build.optimizeCSS === undefined) { if (options.build.optimizeCSS === undefined) {
options.build.optimizeCSS = options.build.extractCSS ? {} : false options.build.optimizeCSS = options.build.extractCSS ? {} : false