问题
AppDelegate.m
#import "Firebase.h"
#import "AppDelegate.h"
#import <React/RCTBundleURLProvider.h>
#import <React/RCTRootView.h>
@implementation AppDelegate
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
[FIRApp configure];
NSURL *jsCodeLocation;
jsCodeLocation = [[RCTBundleURLProvider sharedSettings] jsBundleURLForBundleRoot:@"index" fallbackResource:nil];
RCTRootView *rootView = [[RCTRootView alloc] initWithBundleURL:jsCodeLocation
moduleName:@"kakashi"
initialProperties:nil
launchOptions:launchOptions];
rootView.backgroundColor = [[UIColor alloc] initWithRed:1.0f green:1.0f blue:1.0f alpha:1];
self.window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds];
UIViewController *rootViewController = [UIViewController new];
rootViewController.view = rootView;
self.window.rootViewController = rootViewController;
[self.window makeKeyAndVisible];
return YES;
}
@end
Podfile:
# Uncomment the next line to define a global platform for your project
platform :ios, '9.0'
target 'my_app' do
pod 'Firebase/Core'
end
Verified that Build phase/Link Binary with Libraries
has libRNFirebase.a
I've also verified the $(inherited)
is there for framework search paths.
Still getting error RNFirebase core module was not found natively on iOS
with expo start
or npm start
Can you please recommend how to approach this problem? Or any help with what to verify/ensure for this to work is much appreciated.
来源:https://stackoverflow.com/questions/52247120/rnfirebase-core-module-was-not-found-natively-on-ios