Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Flash of white LaunchScreen.xib after splash screen (iOS) #26971

Closed
JeremyBradshaw7 opened this issue Oct 23, 2019 · 8 comments
Closed

Flash of white LaunchScreen.xib after splash screen (iOS) #26971

JeremyBradshaw7 opened this issue Oct 23, 2019 · 8 comments
Labels
Bug Newer Patch Available Platform: iOS iOS applications. Stale There has been a lack of activity on this issue and it may be closed soon.

Comments

@JeremyBradshaw7
Copy link

JeremyBradshaw7 commented Oct 23, 2019

I'm seeing the standard white screen (LaunchScreen.xib) displayed after my splash screen for a second or two on production builds, this is the one with the app name and the "Powered by React Native" label below. We don't want this displayed at all, and it never used to be but I think came in after upgrading to RN 0.59.10.

The building for production advice hasn't changed and still says:

As your App Bundle grows in size, you may start to see a blank screen flash between your splash screen and the display of your root application view. If this is the case, you can add the following code to AppDelegate.m in order to keep your splash screen displayed during the transition.

// Place this code after "[self.window makeKeyAndVisible]" and before "return YES;"
UIView* launchScreenView = [[[NSBundle mainBundle] loadNibNamed:@"LaunchScreen" owner:self options:nil] objectAtIndex:0];
launchScreenView.frame = self.window.bounds;
rootView.loadingView = launchScreenView;

So we still do this. Is this the same "blank" screen as I'm seeing? Is a change needed here? Should it still work?

React Native version:

~/ccf * PHASE5 > react-native info
info
  React Native Environment Info:
    System:
      OS: macOS 10.14.6
      CPU: (8) x64 Intel(R) Core(TM) i7-4770HQ CPU @ 2.20GHz
      Memory: 74.38 MB / 16.00 GB
      Shell: 3.2.57 - /bin/bash
    Binaries:
      Node: 12.5.0 - /usr/local/bin/node
      Yarn: 1.16.0 - /usr/local/bin/yarn
      npm: 6.10.0 - /usr/local/bin/npm
      Watchman: 4.9.0 - /usr/local/bin/watchman
    SDKs:
      iOS SDK:
        Platforms: iOS 12.2, macOS 10.14, tvOS 12.2, watchOS 5.2
      Android SDK:
        API Levels: 23, 25, 26, 27, 28
        Build Tools: 23.0.1, 23.0.2, 25.0.0, 25.0.1, 25.0.2, 26.0.2, 26.0.3, 27.0.0, 27.0.3, 28.0.2, 28.0.3
        System Images: android-23 | Intel x86 Atom_64, android-23 | Google APIs Intel x86 Atom, android-23 | Google APIs Intel x86 Atom_64, android-27 | Google APIs Intel x86 Atom, android-28 | Google APIs Intel x86 Atom, android-28 | Google Play Intel x86 Atom
    IDEs:
      Android Studio: 3.4 AI-183.6156.11.34.5522156
      Xcode: 10.2.1/10E1001 - /usr/bin/xcodebuild
    npmPackages:
      react: 16.8.3 => 16.8.3
      react-native: ^0.59.10 => 0.59.10
    npmGlobalPackages:
      create-react-native-typescript-app: 1.2.0
      react-native-cli: 2.0.1
      react-native-git-upgrade: 0.2.7
      react-native-html-to-pdf: 0.7.0
      react-native-log-ios: 1.0.1
      react-native-rename: 2.2.2
      react-native-spinkit: 1.3.0

Steps To Reproduce

  1. Do a production build on an app with splash screens (as generated by generator-rn-toolbox)
  2. Deploy to iOS device and start it up, see the splash screen quickly replaced by white "Powered by React Native" screen for a few seconds, then app.

Describe what you expected to happen:

  • splash screen should stay up until app ready.
@react-native-bot
Copy link
Collaborator

It looks like you are using an older version of React Native. Please update to the latest release, v0.61 and verify if the issue still exists.

The "Resolution: Old Version" label will be removed automatically once you edit your original post with the results of running `react-native info` on a project using the latest release.

@JeremyBradshaw7
Copy link
Author

@TikiTDO
Copy link
Contributor

TikiTDO commented Dec 4, 2019

This doesn't seem to really be fixed, if it needs extra 3rd party libs.

@JeremyBradshaw7
Copy link
Author

Happy to re-open if you are experiencing the same issue with 0.61

@maxowy
Copy link

maxowy commented Dec 9, 2019

Try using react-native-splash-screen library.

And then, in AppDelegate.m replace [RNSplashScreen show];
with [RNSplashScreen showSplash:@"LaunchScreen" inRootView:rootView];

@MingyuJeon
Copy link

@maxowy, it doesn't work in my case.

"react": "16.9.0",
"react-native": "0.61.5"

@stale
Copy link

stale bot commented Apr 17, 2020

Hey there, it looks like there has been no activity on this issue recently. Has the issue been fixed, or does it still require the community's attention? This issue may be closed if no further activity occurs. You may also label this issue as a "Discussion" or add it to the "Backlog" and I will leave it open. Thank you for your contributions.

@stale stale bot added the Stale There has been a lack of activity on this issue and it may be closed soon. label Apr 17, 2020
@stale
Copy link

stale bot commented Apr 25, 2020

Closing this issue after a prolonged period of inactivity. If this issue is still present in the latest release, please feel free to create a new issue with up-to-date information.

@stale stale bot closed this as completed Apr 25, 2020
@facebook facebook locked as resolved and limited conversation to collaborators Apr 26, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Bug Newer Patch Available Platform: iOS iOS applications. Stale There has been a lack of activity on this issue and it may be closed soon.
Projects
None yet
Development

No branches or pull requests

6 participants