Browse Source

Merge remote-tracking branch 'upstream/master'

localNotifications
Marcos Rodriguez Vélez 6 years ago
parent
commit
e5d6a1b033
  1. 2
      package.json
  2. 2
      patches/fix_mangle.sh
  3. 20
      patches/metro-bundler+0.9.2.patch

2
package.json

@ -22,7 +22,7 @@
},
"main": "./node_modules/react-native-scripts/build/bin/crna-entry.js",
"scripts": {
"prepare": "git apply -R --ignore-whitespace patches/metro-bundler+0.9.2.patch; git apply patches/transaction_builder.js.patch; git apply ./patches/transaction.js.patch",
"prepare": "./patches/fix_mangle.sh; git apply patches/transaction_builder.js.patch; git apply ./patches/transaction.js.patch",
"start": "react-native-scripts start",
"eject": "react-native-scripts eject",
"android": "react-native-scripts android",

2
patches/fix_mangle.sh

@ -0,0 +1,2 @@
#!/usr/bin/env bash
grep -rl "mangle: { toplevel: true }" ./node_modules/ | xargs sed -i "s/mangle: { toplevel: true }/mangle: false/g"

20
patches/metro-bundler+0.9.2.patch

@ -1,20 +0,0 @@
diff --git a/node_modules/metro-bundler/src/JSTransformer/worker/minify.js b/node_modules/metro-bundler/src/JSTransformer/worker/minify.js
index f2663e1..b7410cb 100644
--- a/node_modules/metro-bundler/src/JSTransformer/worker/minify.js
+++ b/node_modules/metro-bundler/src/JSTransformer/worker/minify.js
@@ -38,7 +38,7 @@ filename)
function minify(inputCode, inputMap) {
const result = uglify.minify(inputCode, {
- mangle: false,
+ mangle: { toplevel: true },
output: {
ascii_only: true,
quote_style: 3,
@@ -63,4 +63,4 @@ function minify(inputCode, inputMap) {
module.exports = {
noSourceMap,
- withSourceMap };
+ withSourceMap };
\ No newline at end of file
Loading…
Cancel
Save