jonathan
03/11/2018, 10:52 AMkotlin-frontend-plugin
, how can I minify the output bundle? The example on the project's GitHub is outdated and causes a crash with the latest webpack:
Error: webpack.optimize.UglifyJsPlugin has been removed, please use config.optimization.minimize instead
anton.bannykh
03/12/2018, 12:36 PMjonathan
03/12/2018, 6:40 PMif(defined.PRODUCTION) {
config.mode = "production";
config.plugins.push(new webpack.DefinePlugin({
"process.env": {
NODE_ENV: JSON.stringify("production")
}
}));
} else {
config.mode = "development";
config.plugins.push(new webpack.DefinePlugin({
"process.env": {
NODE_ENV: JSON.stringify("development")
}
}))
}
2) set sourceMaps = false