Commit b08be165 authored by Alfredo Sumaran's avatar Alfredo Sumaran

Merge branch 'dont-compress-development-assets' into 'master'

Don't compress development assets and fix deprecation warning in production

See merge request !9322
parents 797fcd6b 8c6083a0
...@@ -80,9 +80,6 @@ var config = { ...@@ -80,9 +80,6 @@ var config = {
modules: false, modules: false,
assets: true assets: true
}), }),
new CompressionPlugin({
asset: '[path].gz[query]',
}),
new webpack.IgnorePlugin(/moment/, /pikaday/), new webpack.IgnorePlugin(/moment/, /pikaday/),
], ],
...@@ -102,7 +99,7 @@ var config = { ...@@ -102,7 +99,7 @@ var config = {
if (IS_PRODUCTION) { if (IS_PRODUCTION) {
config.devtool = 'source-map'; config.devtool = 'source-map';
config.plugins.push( config.plugins.push(
new webpack.NoErrorsPlugin(), new webpack.NoEmitOnErrorsPlugin(),
new webpack.LoaderOptionsPlugin({ new webpack.LoaderOptionsPlugin({
minimize: true, minimize: true,
debug: false debug: false
...@@ -112,6 +109,9 @@ if (IS_PRODUCTION) { ...@@ -112,6 +109,9 @@ if (IS_PRODUCTION) {
}), }),
new webpack.DefinePlugin({ new webpack.DefinePlugin({
'process.env': { NODE_ENV: JSON.stringify('production') } 'process.env': { NODE_ENV: JSON.stringify('production') }
}),
new CompressionPlugin({
asset: '[path].gz[query]',
}) })
); );
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment