Rafael Oleza 1dec296000 Downgrade uglify-js from 3.1.8 to 3.1.1
Summary:
Uglify@3.1.7 is causing some perf issues (more specifically, this commit: 5b4b07e9a7) that are impacting TTI on RN views and increased memory usage.

More specifically, code like:

```
function nonTrivialFn(pre) {
  return pre + Math.random();
}
function hotFunctionCalledALotOfTimes(num) {
  return nonTrivialFn(num + Math.random());
}
hotFunctionCalledALotOfTimes(3);
hotFunctionCalledALotOfTimes(5);
```

in v3.1.7 gets converted to:

```
function hotFunctionCalledALotOfTimes(num){
  return function(pre) {
    return pre + Math.random();
  }(num + Math.random())
}
hotFunctionCalledALotOfTimes(3);
hotFunctionCalledALotOfTimes(5);
```

This causes a function creation each time `hotFunctionCalledALotOfTimes` is called.

By comparison, in v3.1.6, that previous code was converted to:

```
function nonTrivialFn(pre){
  return pre + Math.random()
}
function hotFunctionCalledALotOfTimes(num){
  return nonTrivialFn(num + Math.random())
}
hotFunctionCalledALotOfTimes(3);
hotFunctionCalledALotOfTimes(5);
```

Reviewed By: jeanlauliac, alexeylang

Differential Revision: D6296740

fbshipit-source-id: b3988d886e607103ec3ae6b9763b2f0411a8aa3c
2017-11-10 04:52:50 -08:00

54 lines
1.5 KiB
JSON

{
"version": "0.21.0",
"name": "metro-bundler",
"description": "🚇 The JavaScript bundler for React Native.",
"main": "src/index.js",
"repository": {
"type": "git",
"url": "git@github.com:facebook/metro-bundler.git"
},
"scripts": {
"prepare-release": "test -d build && rm -rf src.real && mv src src.real && mv build src",
"cleanup-release": "test ! -e build && mv src build && mv src.real src"
},
"dependencies": {
"absolute-path": "^0.0.0",
"async": "^2.4.0",
"babel-core": "^6.24.1",
"babel-generator": "^6.26.0",
"babel-plugin-external-helpers": "^6.18.0",
"babel-preset-es2015-node": "^6.1.1",
"babel-preset-fbjs": "^2.1.4",
"babel-preset-react-native": "^4.0.0",
"babel-register": "^6.24.1",
"babylon": "^6.18.0",
"chalk": "^1.1.1",
"concat-stream": "^1.6.0",
"core-js": "^2.2.2",
"debug": "^2.2.0",
"denodeify": "^1.2.1",
"fbjs": "^0.8.14",
"graceful-fs": "^4.1.3",
"image-size": "^0.6.0",
"jest-docblock": "21.3.0-beta.8",
"jest-haste-map": "21.3.0-beta.8",
"jest-worker": "21.3.0-beta.8",
"json-stable-stringify": "^1.0.1",
"json5": "^0.4.0",
"left-pad": "^1.1.3",
"lodash": "^4.16.6",
"merge-stream": "^1.0.1",
"mime-types": "2.1.11",
"mkdirp": "^0.5.1",
"request": "^2.79.0",
"rimraf": "^2.5.4",
"source-map": "^0.5.6",
"temp": "0.8.3",
"throat": "^4.1.0",
"uglify-es": "^3.1.0",
"wordwrap": "^1.0.0",
"write-file-atomic": "^1.2.0",
"xpipe": "^1.0.5"
}
}