Closed
Description
Is this a bug report?
Yes
Have you read the Contributing Guidelines?
Yes
Environment
react-native -v
:
react-native-cli: 2.0.0
react-native: n/a - not inside a React Native project directory
(I was inside the folder, version is: 0.47.1)node -v
: v7.10.0npm -v
: 4.2.0yarn --version
: 0.17.10
Then, specify:
- Target Platform: Android, iOS
- Development Operating System: macOS Sierra 10.12.6
- Build tools: Using Xcode 8.3.3 and Android Studio 2.3
Steps to Reproduce
react-native init rn_reproduce_transform_error
cd rn_reproduce_transform_error
react-native run-ios
orreact-native run-android
Expected Behavior
Should show the default "Welcome to React Native!" screen.
Actual Behavior
Same error occurs when I tried to update RN version to 0.48.0-rc.1
Reproducible Demo
https://github.com/esganzerla/rn_reproduce_transform_error
Notes
- This happens both on android and iOS.
- I saw some people having the same problem on issue 0.47.1 Build iOS Error #15496.
Metadata
Metadata
Assignees
Type
Projects
Milestone
Relationships
Development
No branches or pull requests
Activity
tmartres commentedon Aug 16, 2017
Had the same issue and after restarting my computer the issue went away for me. You might have to just close and restart your terminal and simulator too.
phillip-winder commentedon Aug 16, 2017
+1
experiencing the same issue on
run-android
aswell asrun-ios
amerej commentedon Aug 16, 2017
@tmartres Restarting don't work for me
esganzerla commentedon Aug 16, 2017
Restarting didn't help here too.
esganzerla commentedon Aug 16, 2017
I've just found a workaround:
yarn remove babel-preset-react-native
yarn add babel-preset-react-native@2.1.0
The hole is probably deeper, but that is works for me.
jarecsni commentedon Aug 16, 2017
I've tried to create a new RN app by RNCA (Expo) and then eject it. Works perfectly fine, although it runs on React Native 0.46.1, so I'm guessing this is an issue with 0.47.
charpeni commentedon Aug 16, 2017
Thank you for reporting and for the workaround @esganzerla.
It seems an issue with
babel-preset-react-native@3.0.0
that was released earlier.@jeanlauliac How should we fix this issue? Add a specific major version in
react-native-cli
? Or something has been planned?react-native/local-cli/init/init.js
Line 91 in a54d449
cc @ericnakagawa who's on call.
charpeni commentedon Aug 16, 2017
@facebook-github-bot label Tooling
sachinwak commentedon Aug 16, 2017
uninstalling and installing babel-preset-react-native works for me thanks a lot @esganzerla
ivanzotov commentedon Aug 16, 2017
Spent a lot of time trying to fix this issue, PR #15516 but I still don't understand why it works.
ivanzotov commentedon Aug 16, 2017
I just moved plugins from
plugins.push(...
toconst plugins = [...]
37 remaining items