Reputation: 335
Here I'm using xcodebuild shell command to build a release version in my react native project, it comes a fatal error:
'React/RCTViewManager.h' file not found
#import <React/RCTViewManager.h>
Xcode version: 8.3
react native version: 0.44.0
Any help ?
Upvotes: 8
Views: 9336
Reputation: 1205
i solved this issue in easy ways
uninstall react-native-linear gradient cd ios && pod install
after uninstalling completely go to xcode.workspace =>product=>clean build
after successfully running
npm install react-native-linear-gradient then cd ios && pod install
you must see autolinking for react-native-linear gradient
It will work properly
Note = Don't do manually linking if your react native version > 0.60
Upvotes: 0
Reputation: 37
This solved the problem for me
Clear node_module folder and package-lock.json rm -rf node_modules && rm package-lock.json
Clean Xcode's Build folder menu product>clean build folder
Reinstall dependencies and link npm install && react-native link
replace the #import <React/RCTViewManager.h>
by #import "RCTViewManager.h"
Hope it helps you
Upvotes: 1