react-nativebuildprojectnew-operator

React/RCTBridgeDelegate.h' file not found


I have created a new project called auth using react-native init auth at terminal.When i tried to run the project using react-native run-ios. The build failed and gave a error 'React/RCTBridgeDelegate.h' file not found.

Tried to update the react native version

react-native run-ios at terminal in mac

I expect the build to be successful and see the ios simulator The actual result which i got is build failed and hence cant see the simulator


Solution

  • The issue is related to cocoapods dependency manager. Do the following to fix this:

    1. Open the terminal and go to your project ios directory
    2. Type in pod init (If it doesn't exist) and then pod install
    3. Open the workspace project and delete the build from ios folder
    4. Run react-native run-ios from terminal.

    It should work now.