Skip to content

Commit

Permalink
chore: remove unused lodash-es
Browse files Browse the repository at this point in the history
  • Loading branch information
iamandrewluca committed Apr 12, 2020
1 parent 1b89f1f commit 08f0fa3
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 35 deletions.
3 changes: 2 additions & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@
"invariant": "^2.2.4",
"is-promise": "^2.1.0",
"lodash": "^4.17.15",
"lodash-es": "^4.17.15",
"prop-types": "^15.6.1",
"react-is": "^16.4.2"
},
Expand Down
58 changes: 25 additions & 33 deletions webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,42 +4,34 @@ const LodashModuleReplacementPlugin = require('lodash-webpack-plugin')

const env = process.env.NODE_ENV

const reactExternal = {
root: 'React',
commonjs2: 'react',
commonjs: 'react',
amd: 'react'
}

const reduxExternal = {
root: 'Redux',
commonjs2: 'redux',
commonjs: 'redux',
amd: 'redux'
}

const reactReduxExternal = {
root: 'ReactRedux',
commonjs2: 'react-redux',
commonjs: 'react-redux',
amd: 'react-redux'
}

const immutableExternal = {
root: 'Immutable',
commonjs2: 'immutable',
commonjs: 'immutable',
amd: 'immutable'
}

module.exports = {
devtool: env === 'production' ? 'source-map' : false,
externals: {
react: reactExternal,
redux: reduxExternal,
'react-redux': reactReduxExternal,
immutable: immutableExternal
react: {
root: 'React',
commonjs2: 'react',
commonjs: 'react',
amd: 'react'
},
redux: {
root: 'Redux',
commonjs2: 'redux',
commonjs: 'redux',
amd: 'redux'
},
'react-redux': {
root: 'ReactRedux',
commonjs2: 'react-redux',
commonjs: 'react-redux',
amd: 'react-redux'
},
immutable: {
root: 'Immutable',
commonjs2: 'immutable',
commonjs: 'immutable',
amd: 'immutable'
}
},
devtool: env === 'production' ? 'source-map' : false,
mode: env === 'production' ? 'production' : 'development',
module: {
rules: [
Expand Down

0 comments on commit 08f0fa3

Please sign in to comment.