Splashscreen on Android doesn't work (only showing white screen for 2 seconds)

Yes it looks like the plugin registry is pointing to their latest release: 0.3.5 from December. I added the plugin by using the github url which pulled in latest from master:

cordova plugin add GitHub - apache/cordova-plugin-splashscreen: Apache Cordova Plugin splashscreen

To setup the splash screen I followed the steps listed above as everything seems to work like normal.

you mean with crosswalk ?

installing splashscreen plugin from github does the job for me. I am using crosswalk

unfortunately for me ;(

For me it worked i.e. after removing it
(cordova plugin rm org.apache.cordova.splashscreen)
and adding it again directly from the git repo
(cordova plugin add https://github.com/apache/cordova-plugin-splashscreen.git)
the splash screen is back.
Many thanks to @dkeane for the hint :smile:

Now the only problem is that after the splash screen there is a black screen for 2 seconds.

Any ideas how to get rid of it?

I’m using crosswalk.

7 Likes

You may want to increase the time that the splash screen will appear:

Default is 3 seconds, it may be worth making it longer and then hiding it when ionic is ready:

$ionicPlatform.ready(function() {  
	if(navigator.splashscreen) {
		navigator.splashscreen.hide();
	}
}
4 Likes

Thank you very much, it works!

@dkeane many thanks again! Now it works like a charm :smile:

I have the same white screen problem, I installed the crosswalk by CLI, which came out in the last update, installed pluginsplash screen and I generated the icons and splash through the CLI as well.
The icons works but no splash.

Hey @rodrigo_drds, make sure you install the plugin straight from the github url, as mentioned above. I’ve also noticed you need to remove the platform and add it again sometimes for the plugins to work properly.

My configs:
Your system information:

OS: Windows 7 SP1
Node Version: v0.10.35
Cordova CLI: 4.2.0
Ionic Version: 1.0.0-beta.14
Ionic CLI Version: 1.3.3

and plugins
com.ionic.keyboard 1.0.3 "Keyboard"
org.apache.cordova.console 0.2.12 "Console"
org.apache.cordova.device 0.2.13 "Device"
org.apache.cordova.engine.crosswalk 0.0.1-dev "Crosswalk Engine"
org.apache.cordova.splashscreen 0.3.5 “Splashscreen”

preferences in project:

icon e splash in project:

<platform name="android">
<icon src="resources\android\icon\drawable-ldpi-icon.png" density="ldpi"/>
...
<icon src="resources\android\icon\drawable-xxxhdpi-icon.png" density="xxxhdpi"/>
<splash src="resources\android\splash\drawable-land-ldpi-screen.png" density="land-ldpi"/>
...
<splash src="resources\android\splash\drawable-port-xxxhdpi-screen.png" density="port-xxxhdpi"/>

the three points are all variations of icons and splash generated;
and I’m not using the policy still $ cordovaSplashscreen.

I am really stuck with this issue :’( rs

@rodrigo_drds you need to install the Splashscreen from github not from cordova registry, and this will install the version 0.3.6-dev which work like a charm

Version 0.3.5 from Splashscreen does not work with Crosswalk, the dev version works.

1 Like

It worked perfectly with the git link, thank you

All right great, so the splash screen now shows on Android with Crosswalk. Now however comes another problem :slight_smile:

$ionicPlatform.ready(function(){
	$timeout(function(){
		$cordovaSplashscreen.hide();
	}, 10000);
});

10 seconds just for an extreme example. What happens here is that the app launches, showing my splashscreen imge, then the splash screen image disappears and shows a white screen for ~9 seconds, and then it shows my app. So it is “hiding” the splashscreen at the appropriate time, but before then it’s hiding the actual splashscreen image. Anyone else run into this?

I guess the white screen is related to the way Chrome work, but am not sure .

for me I have solved this issue by increasing the time via config.xml like this:

<preference name="SplashScreenDelay" value="15000"/>

Hum could this help: https://github.com/driftyco/ionic-cli/issues/1608

this working for me. http://www.codingandclimbing.co.uk/blog/ionic-2-fix-splash-screen-white-screen-issue-14

I found the solution for your White SplashScreen problem. With the last version of Ionic, you need to verify a line in your config.xml file :

Make sure you have the line :
<preference name="SplashScreen" value="screen"/>

Instead of :
<preference name="SplashScreen" value="splash"/>

You need to have the value “screen” here and not the old version which is “splash” !!!

Now my SplashScreen is not white anymore and it takes my resources files generated from PSD file.

And here is my Ionic Info prompt :

Cordova CLI: 6.3.1
Ionic Framework Version: 2.0.0
Ionic CLI Version: 2.2.1
Ionic App Lib Version: 2.2.0
Ionic App Scripts Version: 1.0.0
ios-deploy version: 1.9.1
ios-sim version: 5.0.13
OS: macOS Sierra
Node Version: v6.9.5
Xcode version: Xcode 8.2.1 Build version 8C1002