Add uglifyjs plugin (#2070)

* Add uglifyjs plugin and replace -p flag with --env.production
* Add uglifyjs plugin
* Configure UglifyJsPlugin to drop console and prevent eslint error
* Turn off no-console rule because uglifyjs plugin drops it in prod
This commit is contained in:
Jason Baciulis
2018-06-16 22:33:41 +07:00
committed by QWp6t
parent 093b5a6500
commit fd2a94fa1b
4 changed files with 14 additions and 3 deletions

View File

@@ -32,7 +32,7 @@ module.exports = {
]
},
"rules": {
"no-console": process.env.NODE_ENV === 'production' ? 2 : 0,
"no-console": 0,
"comma-dangle": [
"error",
{