Skip to content

Commit 9cfd143

Browse files
committed
Adjust config to ensure react is compiled with production code only
1 parent 148033c commit 9cfd143

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

webpack.config.js

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,8 @@ module.exports = env => {
2727
]
2828
},
2929
plugins: [
30+
env.production ? new webpack.DefinePlugin({"process.env": {NODE_ENV: JSON.stringify("production")}}) : '',
3031
env.production ? new webpack.optimize.UglifyJsPlugin() : '',
31-
new webpack.DefinePlugin({
32-
"process.env": {
33-
NODE_ENV: JSON.stringify("production")
34-
}
35-
}),
3632
]
3733
}
3834
};

0 commit comments

Comments
 (0)