react-native: New project fails on react-native@0.46
Is this a bug report?
Yes
Have you read the Bugs section of the Contributing to React Native Guide?
Yes
Environment
react-native -v
: 0.46.0node -v
: 8.1.3npm -v
: 5.0.3yarn --version
(if you use Yarn): 0.27.5
Then, specify:
- Target Platform (e.g. iOS, Android): iOS
- Development Operating System (e.g. macOS Sierra, Windows 10): macOS Sierra (10.12.5 (16F73)
- Build tools (Xcode or Android Studio version, iOS or Android SDK version, if relevant): Xcode 8.3.3
Steps to Reproduce
(Write your steps here:)
- react-native init Test
- cd Test
- react-native run-ios
Expected Behavior
App would go through build process and start app in iOS Simulator, and packager in a terminal window.
Actual Behavior
Error in simulator
Error in packager Terminal Saved Output.pdf
Reproducible Demo
It’s a fresh project built with react-native-cli.
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Reactions: 6
- Comments: 22 (7 by maintainers)
Removing .babelrc seems to temporarily fix the issue
I’ve had a lot of issues with React Native version 0.45 and up. One thing that I found is that React Native doesn’t play well with npm 5. Switch to npm 4. Do this with
npm install -g npm@latest-4
. If that doesn’t help, simply switch to React Native 0.44.0. That’s what I’m using, and you’re not missing out on much by going back. When starting a new project, runreact-native init projectname --version 0.44.0
. Hope that helps!0.46.1 is now out, please give it another go. As always, make sure to clear out your node_modules directory and run
npm install
again.@ryan-burmeister I had no problems on react-native@0.45 with npm 5. This is a new problem in 0.46