Commit 636aed1f authored by Mike Greiling's avatar Mike Greiling

move devtool setting into main config object

parent f2a0f9a8
...@@ -77,6 +77,8 @@ const config = { ...@@ -77,6 +77,8 @@ const config = {
globalObject: 'this', // allow HMR and web workers to play nice globalObject: 'this', // allow HMR and web workers to play nice
}, },
devtool: IS_PRODUCTION ? 'source-map' : 'cheap-module-eval-source-map',
optimization: { optimization: {
nodeEnv: false, nodeEnv: false,
runtimeChunk: 'single', runtimeChunk: 'single',
...@@ -254,8 +256,6 @@ const config = { ...@@ -254,8 +256,6 @@ const config = {
}; };
if (IS_PRODUCTION) { if (IS_PRODUCTION) {
config.devtool = 'source-map';
// compression can require a lot of compute time and is disabled in CI // compression can require a lot of compute time and is disabled in CI
if (!NO_COMPRESSION) { if (!NO_COMPRESSION) {
config.plugins.push(new CompressionPlugin()); config.plugins.push(new CompressionPlugin());
...@@ -263,7 +263,6 @@ if (IS_PRODUCTION) { ...@@ -263,7 +263,6 @@ if (IS_PRODUCTION) {
} }
if (IS_DEV_SERVER) { if (IS_DEV_SERVER) {
config.devtool = 'cheap-module-eval-source-map';
config.devServer = { config.devServer = {
host: DEV_SERVER_HOST, host: DEV_SERVER_HOST,
port: DEV_SERVER_PORT, port: DEV_SERVER_PORT,
......
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