Cordova - White Screen After Splash, No Exceptions in Console

Cordova - white screen after splash, no exceptions in console

Well that was ugly. It turned out that there was an exception being thrown, it was just being thrown too early for the browser dev tools to pick it up (Safari, Chrome for iOS and Android, respectively). The exception did show up when I ran things through the browser target (cordova platform add browser, etc.) So that browser platform is useful for something I guess. :-)

In my case, the cordova-sqlite-storage plugin had made a breaking API change that broke the code when I updated everything. The solution was to pin the plugin to an earlier version in the config.xml file.

So, lessons learned:

  • If you suspect there's an exception being thrown during startup, you can use the browser platform to track it down.
  • Pin your plugins to a specific version using the spec parameter in the config.xml. This will save you some heartache in the future.
  • [another option from @jcesarmobile, below] hitting refresh in the browser dev tools will also kick out the exception. Nice!

I'll be going back in to the config.xml and pinning the other items -- and doing some cleanup as suggested above. Thanks again, everyone.

How to fix while screen after splash screen in cordova ios?

You are probably facing the same issue I was facing a while ago. Start off by not auto hiding the splash screen. Instead hide it on "deviceready".

To stop autohiding splash screen add the following line to config.xml

<preference name="AutoHideSplashScreen" value="false" />

To manually hide splash screen add the following inside the deviceready event in your entry point( probably index.html or the js file you are using in it for app namespace )

navigator.splashscreen.hide();

For more information, head to cordova-plugin-splashscreen documentation.

Why white screen stuck after splash screen in Ionic 4?

I’ve solved this issue by setting the correct parameters on config.xml

<preference name="AutoHideSplashScreen" value="false" />
<preference name="SplashScreenDelay" value="10000" />
<preference name="FadeSplashScreenDuration" value="1000" />
<preference name="SplashScreen" value="screen" />
<preference name="ShowSplashScreen" value="true" />
<preference name="ShowSplashScreenSpinner" value="false" />
<preference name="SplashShowOnlyFirstTime" value="false" />
<preference name="FadeSplashScreen" value="true" />

Then, on my platform.ready() instruction all I do is Splashscreen.hide() and after that run the project on android using.

ionic cordova run android

PhoneGap Build iOS app has blank white screen after splash screen

Totally feel your pain on this. The docs for PhoneGap Build need a lot of work.
I've been fighting with this the last couple of days myself. After much trial and error, this is what has worked for me.

Within config.xml:

<!-- Do not auto hide splash on iOS -->
<preference name="AutoHideSplashScreen" value="false" />
<!-- Do not auto hide splash on Android -->
<preference name="SplashScreenDelay" value="10000"/>

<gap:plugin name="org.apache.cordova.splashscreen" />

Android does not seem to have an AutoHide param, so we just give it a long delay. We will hide it manually with JS before this 10 seconds is reached.

Adding the plugin reference in the config.xml is needed for the javascript code navigator.splashscreen.hide(); to work.

Also, I found for my project (using Kendo UI Mobile) that no setTimeout delay was needed within onDeviceReady. I am guessing, that once you get the correct params within your config.xml, you will see the same in your app.

My onDeviceReady looks like this:

document.addEventListener('deviceready', function() {
navigator.splashscreen.hide();
});

Tested on iOS 6, and Android 4.1 using PhoneGap Build 3.1.

App shows blank white screen in iOS 8.1

Ionic 2 support ios 8, 8.1 . Should you run your app on emulator ios 8 and view log on safari ? It help you detect your problem.
Reference this link to know view log on safari.

Cheer!

White screen flashing on iOS Cordova app

To get rid of this, the only solution I found was to install the splashscreen plugin and create a black screen image. I also set the preference TopActivityIndicator to whiteLarge. Too bad that Cordova does not work better out of the box.



Related Topics



Leave a reply



Submit