I have create sample React Native project and following the tutorial as per react native website.
I have try to run the application IOS simulator, its throwing error
Usually, this error comes up due to inconsistent versions (either of react-native, OS or XCode). I had the same issue with react-native v0.57.0
on MacOS Sierra and XCode v9.x
.
All I had to do was to upgrade to High Sierra and then XCode to v10.0
.
Otherwise, you'd have to use an older version of react-native either by downgrading it or by initialising a project with an older version
react-native init test --version react-native@0.x.x
For anyone still have this problem,I myself experienced this due to the xcode 12 upgrade. i solved my problem by upgrading my rn by using this command :
react-native upgrade
then go to podfile change your
pod 'ReactCommon/callinvoker', :path => "../node_modules/react-native/ReactCommon"
to
pod 'React-callinvoker', :path => "../node_modules/react-native/ReactCommon/callinvoker"
Good luck!
Do you have CFBundleIdentifier in your Info.plist?
If not than add it for eg. com.ios.learning
I have same problem
react-native upgrade
Take my project to v0.57.3 And it works perfect now.
npm uninstall react-native
delete ios and android folder then run :
npm install react-native
react-native upgrade
I have the same problem right after init:
react-native init myapp
cd myapp
react-native run-ios
..although run-android was fine.
Not a solution but a workaround for the moment, maybe be to init using a lower version of RN:
react-native init myapp --version react-native@0.51.0
That builds okay. Similar in an existing project, install an older version of RN.
Other versions before 0.54.2 might work but I haven't tried.
(edited 2018/4/2) Found my solution from this link: https://github.com/facebook/react-native/issues/18238
RN 0.54 requires types available since iOS 11. So you have to upgrade your xcode and set minimum iOS version in your app to 11
In short, upgraded OSX & Xcode to the latest. (As of today, OSX 10.13.4 Xcode & 9.3)