mirror of
https://github.com/status-im/react-native-webview.git
synced 2025-02-24 01:38:45 +00:00
40 lines
981 B
Objective-C
40 lines
981 B
Objective-C
/**
|
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
*
|
|
* This source code is licensed under the MIT license found in the
|
|
* LICENSE file in the root directory of this source tree.
|
|
*/
|
|
|
|
#import "AppDelegate.h"
|
|
|
|
#import <React/RCTBridge.h>
|
|
#import <React/RCTBundleURLProvider.h>
|
|
|
|
@interface AppDelegate () <RCTBridgeDelegate>
|
|
|
|
@end
|
|
|
|
@implementation AppDelegate
|
|
|
|
- (void)awakeFromNib {
|
|
[super awakeFromNib];
|
|
|
|
_bridge = [[RCTBridge alloc] initWithDelegate:self launchOptions:nil];
|
|
}
|
|
|
|
- (void)applicationDidFinishLaunching:(NSNotification *)aNotification {
|
|
// Insert code here to initialize your application
|
|
}
|
|
|
|
- (void)applicationWillTerminate:(NSNotification *)aNotification {
|
|
// Insert code here to tear down your application
|
|
}
|
|
|
|
#pragma mark - RCTBridgeDelegate Methods
|
|
|
|
- (NSURL *)sourceURLForBridge:(__unused RCTBridge *)bridge {
|
|
return [[RCTBundleURLProvider sharedSettings] jsBundleURLForBundleRoot:@"example/index" fallbackResource:@"main"]; // .jsbundle;
|
|
}
|
|
|
|
@end
|