Merge pull request #667 from metamaps/feature/update-package.json

update package.json and save a bit of bundle size
This commit is contained in:
Devin Howard 2016-09-25 22:25:31 +08:00 committed by GitHub
commit cc986368be
3 changed files with 11 additions and 9 deletions

View file

@ -4,6 +4,7 @@
"es2015" "es2015"
], ],
"plugins": [ "plugins": [
"lodash",
"transform-class-properties" "transform-class-properties"
] ]
} }

View file

@ -19,20 +19,20 @@
"homepage": "https://github.com/metamaps/metamaps#readme", "homepage": "https://github.com/metamaps/metamaps#readme",
"dependencies": { "dependencies": {
"autolinker": "0.17.1", "autolinker": "0.17.1",
"babel-cli": "6.11.4", "babel-cli": "6.14.0",
"babel-loader": "6.2.4", "babel-loader": "6.2.5",
"babel-plugin-lodash": "^3.2.9",
"babel-plugin-transform-class-properties": "6.11.5", "babel-plugin-transform-class-properties": "6.11.5",
"babel-preset-es2015": "6.9.0", "babel-preset-es2015": "6.14.0",
"babel-preset-react": "6.11.1", "babel-preset-react": "6.11.1",
"backbone": "1.0.0", "backbone": "1.0.0",
"csv-parse": "1.1.7", "csv-parse": "1.1.7",
"node-uuid": "1.2.0", "lodash": "4.16.1",
"react": "15.3.0", "node-uuid": "1.4.7",
"react-dom": "15.3.0", "react": "15.3.2",
"requirejs": "2.1.1", "react-dom": "15.3.2",
"socket.io": "0.9.12", "socket.io": "0.9.12",
"underscore": "1.4.4", "webpack": "1.13.2"
"webpack": "1.13.1"
}, },
"devDependencies": { "devDependencies": {
"chai": "^3.5.0", "chai": "^3.5.0",

View file

@ -9,6 +9,7 @@ const plugins = [
}) })
] ]
if (NODE_ENV === 'production') { if (NODE_ENV === 'production') {
plugins.push(new webpack.optimize.DedupePlugin())
plugins.push(new webpack.optimize.UglifyJsPlugin({ plugins.push(new webpack.optimize.UglifyJsPlugin({
compress: { warnings: false } compress: { warnings: false }
})) }))