webmastx
webmastx

Reputation: 683

React Native Navigation React/RCTRootView.h file not found

enter image description here

I'm try to use React Native Navigation refer to this instruction https://wix.github.io/react-native-navigation/#/installation-ios

I stuck at step 3 when I link the libReactNativeNavigation.a Xcode show error and I don't know how to fix this issue!

Here my package.json

"dependencies": {
    "react": "~16.2.0",
    "react-native": "~0.51.0",
    "react-native-navigation" : "1.1.428"

  }

My Pod file

source 'https://github.com/CocoaPods/Specs.git'

platform :ios, '10.0'

target 'MyApp' do
  # Comment the next line if you're not using Swift and don't want to use dynamic frameworks
  use_frameworks!

  # Pods for React
  pod 'React', :path => '../js/node_modules/react-native', :subspecs => [
  'Core',
  'CxxBridge', # Include this for RN >= 0.47
  'DevSupport', # Include this to enable In-App Devmenu if RN >= 0.43
  'RCTImage',
  'RCTNetwork',
  'RCTText',
  'RCTWebSocket',
]
   # Explicitly include Yoga if you are using RN >= 0.42.0
  pod "yoga", :path => "../js/node_modules/react-native/ReactCommon/yoga"

  # Third party deps podspec link
  pod 'DoubleConversion', :podspec => '../js/node_modules/react-native/third-party-podspecs/DoubleConversion.podspec'
  pod 'GLog', :podspec => '../js/node_modules/react-native/third-party-podspecs/GLog.podspec'
  pod 'Folly', :podspec => '../js/node_modules/react-native/third-party-podspecs/Folly.podspec'

Upvotes: 1

Views: 2670

Answers (1)

Candy Hu
Candy Hu

Reputation: 11

It's because that React-Native-Navigation is a subproject of your project, and it has dependency with React which you added to your project via cocoapods.

Try add ${BUILT_PRODUCTS_DIR} recursive to Build Settings -> FRAMEWORK_SEARCH_PATHS in ReactNativeNavigation.xcodeproj

Upvotes: 1

Related Questions