From 0315c0b72158a2ae3cc827c6922a4dbcbef3a002 Mon Sep 17 00:00:00 2001 From: Christine Dodrill Date: Sun, 18 Dec 2016 08:51:15 -0800 Subject: [PATCH] frontend: make webpack better --- frontend/webpack.production.config.js | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/frontend/webpack.production.config.js b/frontend/webpack.production.config.js index ac58a43..4383a1e 100644 --- a/frontend/webpack.production.config.js +++ b/frontend/webpack.production.config.js @@ -41,18 +41,18 @@ module.exports = { }), new FaviconsWebpackPlugin('../static/img/avatar.png'), new webpack.optimize.DedupePlugin(), - new webpackUglifyJsPlugin({ - cacheFolder: path.resolve(__dirname, 'output/ug'), - debug: false, - minimize: true, - sourceMap: false, - output: { - comments: false - }, - compressor: { + new webpack.optimize.UglifyJsPlugin({ + beautify: false, + mangle: true, + comments: false, + compress: { + dead_code: true, + loops: true, + if_return: true, + unused: true, warnings: false } - }), + }) ], resolveLoader: { modules: [