Fix orientation change issue in HelloWord template (#20945)

Summary:
This commit is related to issue #16060
Tested through the iOS simulator. Solution came from https://moduscreate.com/blog/changing-the-react-native-rootview-background-color-ios-and-android/
Pull Request resolved: https://github.com/facebook/react-native/pull/20945

Differential Revision: D9661761

Pulled By: hramos

fbshipit-source-id: ca8dd3fd09a0b0e89e1598a8114800808efa7d21
This commit is contained in:
Peter Keller 2018-09-05 13:04:31 -07:00 committed by Facebook Github Bot
parent 27a07cf13c
commit d985b2e661
1 changed files with 1 additions and 1 deletions

View File

@ -22,7 +22,7 @@
moduleName:@"HelloWorld" moduleName:@"HelloWorld"
initialProperties:nil initialProperties:nil
launchOptions:launchOptions]; launchOptions:launchOptions];
rootView.backgroundColor = [[UIColor alloc] initWithRed:1.0f green:1.0f blue:1.0f alpha:1]; rootView.backgroundColor = [UIColor blackColor];
self.window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds]; self.window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds];
UIViewController *rootViewController = [UIViewController new]; UIViewController *rootViewController = [UIViewController new];