react-native/packager/package.json

44 lines
1.1 KiB
JSON
Raw Normal View History

{
create better debuggable source maps Summary: Introduces a new mechanism to build source maps that allows us to use real mapping segments instead of just mapping line-by-line. This mechanism is only used when building development bundles to improve the debugging experience in Chrome. The new mechanism takes advantage of a new feature in babel-generator that exposes raw mapping objects. These raw mapping objects are converted to arrays with 2, 4, or 5 for the most compact representation possible. We no longer generate a source map for the bundle that maps each line to itself in conjunction with configuring babel generator to retain lines. Instead, we create a source map with a large mappings object produced from the mappings of each individual file in conjunction with a “carry over” – the number of preceding lines in the bundle. The implementation makes a couple of assumptions that hold true for babel transform results, e.g. mappings being in the order of the generated code, and that a block of mappings always belongs to the same source file. In addition, the implementation avoids allocation of objects and strings at all costs. All calculations are purely numeric, and base64 vlq produces numeric ascii character codes. These are written to a preallocated buffer objects, which is turned to a string only at the end of the building process. This implementation is ~5x faster than using the source-map library. In addition to providing development source maps that work better, we can now also produce individual high-quality source maps for production builds and combine them to an “index source map”. This approach is unfeasable for development source maps, because index source map consistently crash Chrome. Better production source maps are useful to get precise information about source location and symbol names when symbolicating stack traces from crashes in production. Reviewed By: jeanlauliac Differential Revision: D4382290 fbshipit-source-id: 365a176fa142729d0a4cef43edeb81084361e54d
2017-01-12 22:21:59 +00:00
"version": "0.5.0",
"name": "react-native-packager",
"description": "Build native apps with React!",
"repository": {
"type": "git",
"url": "git@github.com:facebook/react-native.git"
},
"dependencies": {
"absolute-path": "^0.0.0",
"async": "^2.0.1",
"babel-core": "^6.21.0",
"babel-generator": "^6.21.0",
"babel-plugin-external-helpers": "^6.18.0",
"babel-preset-fbjs": "^2.1.0",
"babel-preset-react-native": "^1.9.1",
"babel-register": "^6.18.0",
"babylon": "^6.14.1",
"chalk": "^1.1.1",
"core-js": "^2.2.2",
"debug": "^2.2.0",
"denodeify": "^1.2.1",
"fbjs": "^0.8.9",
"graceful-fs": "^4.1.3",
"image-size": "^0.3.5",
"imurmurhash": "^0.1.4",
"jest-haste-map": "18.0.0",
"joi": "^6.6.1",
"json-stable-stringify": "^1.0.1",
"json5": "^0.4.0",
"left-pad": "^1.1.3",
"lodash": "^4.16.6",
"mime-types": "2.1.11",
"mkdirp": "^0.5.1",
"request": "^2.79.0",
"rimraf": "^2.5.4",
"source-map": "^0.5.6",
"throat": "^3.0.0",
"uglify-js": "^2.6.2",
"worker-farm": "^1.3.1",
"write-file-atomic": "^1.2.0"
}
}