aboutsummaryrefslogtreecommitdiffstats
path: root/packages/0x.js/webpack.config.js
diff options
context:
space:
mode:
authorBrandon Millman <brandon@0xproject.com>2018-08-24 06:21:54 +0800
committerGitHub <noreply@github.com>2018-08-24 06:21:54 +0800
commit2c660e62d34bc59957c04a52fb43975470f009e7 (patch)
tree5e5883719a8eadaa782e1cf97a285b9b9e2f7fe0 /packages/0x.js/webpack.config.js
parent6e27324a341801e1a2d8d6989d749dfe021ae39b (diff)
parentd52c1310b28a574f9ef4fe558cfe1ef508a64d7c (diff)
downloaddexon-sol-tools-2c660e62d34bc59957c04a52fb43975470f009e7.tar
dexon-sol-tools-2c660e62d34bc59957c04a52fb43975470f009e7.tar.gz
dexon-sol-tools-2c660e62d34bc59957c04a52fb43975470f009e7.tar.bz2
dexon-sol-tools-2c660e62d34bc59957c04a52fb43975470f009e7.tar.lz
dexon-sol-tools-2c660e62d34bc59957c04a52fb43975470f009e7.tar.xz
dexon-sol-tools-2c660e62d34bc59957c04a52fb43975470f009e7.tar.zst
dexon-sol-tools-2c660e62d34bc59957c04a52fb43975470f009e7.zip
Merge pull request #1006 from 0xProject/fix/0x.js/uglify-plugin
[0x.js] Update uglify plugin to support es6
Diffstat (limited to 'packages/0x.js/webpack.config.js')
-rw-r--r--packages/0x.js/webpack.config.js13
1 files changed, 10 insertions, 3 deletions
diff --git a/packages/0x.js/webpack.config.js b/packages/0x.js/webpack.config.js
index 2c1fe81a7..982e076ee 100644
--- a/packages/0x.js/webpack.config.js
+++ b/packages/0x.js/webpack.config.js
@@ -3,6 +3,7 @@
*/
const _ = require('lodash');
const webpack = require('webpack');
+const UglifyJsPlugin = require('uglifyjs-webpack-plugin');
const path = require('path');
const production = process.env.NODE_ENV === 'production';
@@ -27,10 +28,16 @@ module.exports = {
},
devtool: 'source-map',
plugins: [
- new webpack.optimize.UglifyJsPlugin({
- minimize: true,
+ // TODO: Revert to webpack bundled version with webpack v4.
+ // The v3 series bundled version does not support ES6 and
+ // fails to build.
+ new UglifyJsPlugin({
sourceMap: true,
- include: /\.min\.js$/,
+ uglifyOptions: {
+ mangle: {
+ reserved: ['BigNumber'],
+ },
+ },
}),
],
module: {