react native ios build fails with error - 'EXUpdates/EXUpdatesAppController.h' file not found

Viewed 6098

react native ios build fails with error

'EXUpdates/EXUpdatesAppController.h' file not found

file used in AppDelegate.h

#import <Foundation/Foundation.h>
#import <EXUpdates/EXUpdatesAppController.h>  <--- here
#import <React/RCTBridgeDelegate.h>
#import <UIKit/UIKit.h>

#import <UMCore/UMAppDelegateWrapper.h>

@interface AppDelegate : UMAppDelegateWrapper <RCTBridgeDelegate, EXUpdatesAppControllerDelegate>

@end

Anyone solutions?

2 Answers

This error means that Xcode is unable to find the package that is supposed to be in your development pod folder ( at least that is the case for me)

Few points to double check:

  1. Ensure that you have your react-native-unimodules installed and is reflected in your package.json.

  2. Ensure that expo-updates package is installed. Else run npm install expo-updates --save or use the yarn command.

  3. In your Podfile, ensure you have this line : use_unimodules!

After ensuring both are there, run cd ios followed by pod install to install the EX modules. The modules should be in your 'Development Pods' folder. Lastly, rebuild your xcode project. These ways work for me. Hopefully, they can be of some help.

Yes, as Kakoma says it is very necessary to place the route:

require_relative '../node_modules/react-native-unimodules/cocoapods'

at the beginning of the Podfile to avoid the following error:

Invalid Podfile file: undefined method use_unimodules! ' for # <Pod :: Podfile:

Related