Skip to content

Commit

Permalink
Use ES5 compatible camelcase library. (#309)
Browse files Browse the repository at this point in the history
* Use ES5 compatible camelcase library.

* Remove devtool. Can remove all of es-check if no automated tests are wanted for now.
  • Loading branch information
nowells authored and timche committed Jul 25, 2018
1 parent 3bc36a2 commit e6dbdee
Show file tree
Hide file tree
Showing 3 changed files with 212 additions and 19 deletions.
5 changes: 3 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"build:es": "cross-env BABEL_ENV=es babel src --out-dir es",
"build:commonjs": "cross-env BABEL_ENV=commonjs babel src --out-dir lib",
"build:umd": "cross-env NODE_ENV=development webpack",
"build:umd:min": "cross-env NODE_ENV=production webpack",
"build:umd:min": "cross-env NODE_ENV=production webpack && es-check es5 dist/redux-actions.min.js",
"build": "run-s clean && run-p build:**",
"clean": "rimraf coverage dist es lib",
"lint": "xo",
Expand Down Expand Up @@ -49,6 +49,7 @@
"babel-plugin-transform-object-rest-spread": "^6.26.0",
"babel-preset-env": "^1.6.1",
"cross-env": "^2.0.0",
"es-check": "^2.0.4",
"eslint-config-jest-files": "^0.1.1",
"eslint-config-unicorn-camelcase": "^0.1.1",
"eslint-plugin-prettier": "^2.6.0",
Expand All @@ -64,11 +65,11 @@
"xo": "^0.20.3"
},
"dependencies": {
"camelcase": "^5.0.0",
"invariant": "^2.2.1",
"is-function": "^1.0.1",
"is-plain-object": "^2.0.4",
"is-symbol": "^1.0.1",
"lodash.camelcase": "^4.3.0",
"lodash.curry": "^4.1.1",
"reduce-reducers": "^0.1.0"
},
Expand Down
4 changes: 2 additions & 2 deletions src/utils/camelCase.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import camelCase from 'camelcase';
import camelCase from 'lodash.camelcase';

const namespacer = '/';

Expand All @@ -7,5 +7,5 @@ export default type =>
? camelCase(type)
: type
.split(namespacer)
.map(camelCase)
.map(part => camelCase(part))
.join(namespacer);
Loading

0 comments on commit e6dbdee

Please sign in to comment.