Skip to content

Commit

Permalink
Use uglifyify to remove conditional invariant require
Browse files Browse the repository at this point in the history
  • Loading branch information
Brandon Dail authored and gaearon committed Apr 11, 2017
1 parent 38ba18a commit 7882a72
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 2 deletions.
3 changes: 2 additions & 1 deletion package.json
Expand Up @@ -31,7 +31,7 @@
"scripts": {
"test": "jest",
"umd": "NODE_ENV=development browserify index.js -t envify --standalone PropTypes -o prop-types.js",
"umd-min": "NODE_ENV=production browserify index.js -t envify --standalone PropTypes -p bundle-collapser/plugin -o | uglifyjs --compress unused,dead_code -o prop-types.min.js",
"umd-min": "NODE_ENV=production browserify index.js -t envify -t uglifyify --standalone PropTypes -p bundle-collapser/plugin -o | uglifyjs --compress unused,dead_code -o prop-types.min.js",
"build": "yarn umd && yarn umd-min",
"prepublish": "yarn build"
},
Expand All @@ -43,6 +43,7 @@
"envify": "^4.0.0",
"jest": "^19.0.2",
"react": "^15.5.1",
"uglifyify": "^3.0.4",
"uglifyjs": "^2.4.10"
}
}
16 changes: 15 additions & 1 deletion yarn.lock
Expand Up @@ -1010,6 +1010,10 @@ expand-range@^1.8.1:
dependencies:
fill-range "^2.1.0"

extend@^1.2.1:
version "1.3.0"
resolved "http://npme.walmart.com/extend/-/extend-1.3.0.tgz#d1516fb0ff5624d2ebf9123ea1dac5a1994004f8"

extend@~3.0.0:
version "3.0.0"
resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.0.tgz#5a474353b9f3353ddd8176dfd37b91c83a46f1d4"
Expand Down Expand Up @@ -2748,7 +2752,7 @@ ua-parser-js@^0.7.9:
version "0.7.12"
resolved "https://registry.yarnpkg.com/ua-parser-js/-/ua-parser-js-0.7.12.tgz#04c81a99bdd5dc52263ea29d24c6bf8d4818a4bb"

uglify-js@^2.6:
uglify-js@2.x.x, uglify-js@^2.6:
version "2.8.21"
resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-2.8.21.tgz#1733f669ae6f82fc90c7b25ec0f5c783ee375314"
dependencies:
Expand All @@ -2761,6 +2765,16 @@ uglify-to-browserify@~1.0.0:
version "1.0.2"
resolved "https://registry.yarnpkg.com/uglify-to-browserify/-/uglify-to-browserify-1.0.2.tgz#6e0924d6bda6b5afe349e39a6d632850a0f882b7"

uglifyify@^3.0.4:
version "3.0.4"
resolved "http://npme.walmart.com/uglifyify/-/uglifyify-3.0.4.tgz#487e080a5a7798880e68e90def9b06681fb13bd2"
dependencies:
convert-source-map "~1.1.0"
extend "^1.2.1"
minimatch "^3.0.2"
through "~2.3.4"
uglify-js "2.x.x"

uglifyjs@^2.4.10:
version "2.4.10"
resolved "https://registry.yarnpkg.com/uglifyjs/-/uglifyjs-2.4.10.tgz#632927319fa6a3da3fc91f9773ac27bfe6c3ee92"
Expand Down

0 comments on commit 7882a72

Please sign in to comment.