jsc-android-buildscripts icon indicating copy to clipboard operation
jsc-android-buildscripts copied to clipboard

New preset

Open JacquesBonet opened this issue 5 years ago • 2 comments

Issue Description

Its not an issue but more an interrogation.

You provide a new JSC, greate job. But why you don't change the metro-react-native-preset? metro-react-native-preset embed many plugins to transpile code to ecmascript, so the es6/es7/es8 language implementation by the new JSC are not use.

In my opinion, would be better to create a new preset containing only the babel plugins not implemented in the new JSC.

What your opinion?

Regards

JacquesBonet avatar Dec 12 '18 17:12 JacquesBonet

Some plugins are still needed depending on what the minimum iOS release is targeted. iOS 9 is the minimum for React Native, and it still requires many of the ES6 transforms. Nevertheless, it might be helpful to include in the README here what transforms are required by this runtime. Then folks can customize their babel config as needed.

newyankeecodeshop avatar Dec 12 '18 17:12 newyankeecodeshop

I modified metro-react-native-babel-preset, removing some babel plugins in package.json and in src/config/mains.js. I obtain the same apk, so I think babel check what Javascript release support the APK. Thks for your help newyankeecode

JacquesBonet avatar Dec 12 '18 18:12 JacquesBonet