feat:update cli target files

This commit is contained in:
pengfei.zhou
2019-12-23 17:59:19 +08:00
committed by osborn
parent c1776f6f25
commit 667c233d63
4 changed files with 13 additions and 18 deletions

View File

@@ -7,7 +7,7 @@
//
#import "AppDelegate.h"
#import <Doric/Doric.h>
#import <DoricCore/Doric.h>
@interface AppDelegate ()
@end
@@ -17,7 +17,9 @@ @implementation AppDelegate
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
NSString *bundleName = @"__$__";
DoricViewController *doricViewController = [[DoricViewController alloc] initWithScheme:[NSString stringWithFormat:@"assets://src/%@.js", bundleName] alias:bundleName];
DoricViewController *doricViewController = [[DoricViewController alloc] initWithScheme:[NSString stringWithFormat:@"assets://src/%@.js", bundleName]
alias:bundleName
extra:@""];
self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
UINavigationController *navVC = [[UINavigationController
alloc] initWithRootViewController:doricViewController];

View File

@@ -1,5 +1,5 @@
#import "SceneDelegate.h"
#import <Doric/Doric.h>
#import <DoricCore/Doric.h>
@interface SceneDelegate ()
@end
@@ -8,7 +8,9 @@ @implementation SceneDelegate
- (void)scene:(UIScene *)scene willConnectToSession:(UISceneSession *)session options:(UISceneConnectionOptions *)connectionOptions {
UIWindowScene *windowScene = (UIWindowScene *) scene;
NSString *bundleName = @"__$__";
DoricViewController *doricViewController = [[DoricViewController alloc] initWithScheme:[NSString stringWithFormat:@"assets://src/%@.js", bundleName] alias:bundleName];
DoricViewController *doricViewController = [[DoricViewController alloc] initWithScheme:[NSString stringWithFormat:@"assets://src/%@.js", bundleName]
alias:bundleName
extra:@""];
doricViewController.view.backgroundColor = [UIColor whiteColor];
UINavigationController *navigationController = [[UINavigationController alloc] initWithRootViewController:doricViewController];
self.window = [[UIWindow alloc] initWithWindowScene:windowScene];