I am getting this getting when using import branch from 'react-native-branch' in the ios simulator but it works fine on the device.
How can I fix this? Thanks
@kelvinblade I'm also getting this error. Did you manage to find a fix?
Having the same error, Anyone knows a solution?
+1
+1
I had my getPackages() function explicitly/manually set to the list of native packages, and following the tutorial, I had missed the same for react-native-branch. Doing this in MainApplication.java solved the error for me:
import io.branch.rnbranch.RNBranchPackage;
@Override
protected List<ReactPackage> getPackages() {
return Arrays.<ReactPackage>asList(
new MainReactPackage(),
// bugsnag
BugsnagReactNative.getPackage(),
// react-native-branch
new RNBranchPackage()
);
}
Any updates on this? I am getting this error in ios simulator
+1
Have you tried ?
react-native link react-native-branch
pod install
Most helpful comment
@kelvinblade I'm also getting this error. Did you manage to find a fix?