Splash screen shows default ionic cordova splash briefly even with custom resources


#1

I’ve successfully run ionic cordova resources, and I’ve even looked and manually checked all of the images inside the folders and the build, and they look correct.

However, when I launch the app on my phone, the default splash screen shows briefly, then it is replaced with the correct splash screen. Any idea what could be causing this? I can’t even find the file with the default splash screen anymore since running the resources command, so I’m not sure where it’s coming from.

I’ve tried deleting and rebuilding and installing the app as well, and that default image still appears briefly.

**Update - just updated to XCode 9, not sure if that might have something to do with it


#2

How are you building your app?
What is your ionic info output?


#3

I build by running ionic cordova prepare ios, ionic cordova run ios --device

here’s the info:


cli packages: (/usr/local/lib/node_modules)

    @ionic/cli-utils  : 1.13.1
    ionic (Ionic CLI) : 3.13.2

global packages:

    cordova (Cordova CLI) : 7.1.0 

local packages:

    @ionic/app-scripts : 3.0.0
    Cordova Platforms  : ios 4.5.2
    Ionic Framework    : ionic-angular 3.7.1

System:

    Android SDK Tools : 25.2.5
    ios-deploy        : 1.9.2 
    Node              : v8.5.0
    npm               : 5.5.1 
    OS                : macOS Sierra
    Xcode             : Xcode 9.0.1 Build version 9A1004 

Misc:

    backend : pro

#4

I am also seeing this today, using xcode 8, but on a iPad 3 running iOS 11.


#5

Yes this is a new issue that wasn’t happening just a few days ago even. But it’s pretty bad I don’t want my users seeing the default ionic splash screen before my logo every time they launch the app.

I’m digging through the entire build package to try to find if / where this file still exists or how it’s getting in there after Ionic Resources…still lost at this point :confused:


#6

This might help the investigation: The initial splash screen is probably the native app splash, the second one then handled by the splashcreen Cordova plugin. Remove the splashscreen.hide in the platform.ready to check if the correct splashscreen stays.

Are you both testing on the same devices? Only on one device or on all?


#7

This worked, I’m not sure why, so in effect…if I’m not calling splashscreen.hide(), how is my splash screen ( the correct one ) being hidden?

Either way - good call :slight_smile:


#8

Wait, this wasn’t supposed to help, just to enable you to debug this further!? What is happening now?
I think the splash screen is automatically hidden via a setting in config.xml after a set time frame.


#9

I am still getting this issue after removing splashScreen.hide()

cli packages: (/usr/local/lib/node_modules)

@ionic/cli-utils  : 1.14.0
ionic (Ionic CLI) : 3.14.0

global packages:

cordova (Cordova CLI) : 7.1.0 

local packages:

@ionic/app-scripts : 3.0.0
Cordova Platforms  : ios 4.5.2
Ionic Framework    : ionic-angular 3.7.1

System:

ios-deploy : 1.9.2 
ios-sim    : 5.0.9 
Node       : v7.4.0
npm        : 5.5.1 
OS         : OS X El Capitan
Xcode      : Xcode 8.2.1 Build version 8C1002 

Misc:

backend : pro

#10

I removed that line of code and the same issue remained.
You can see my specs in a previous reply/

Also, I tried downgrading to ionic 2.2, but the problem persisted.

I have also noticed that when I double-tap the home button on the iPad 3, the icon showing for my app is the default ionic one


#11

I resolved my issue. After trying a different iOS device, I noticed that the problem didn’t reoccur.
After carrying out a full reset of the iPad 3, the app worked fine.


#12

I’m having the exact same problem

Briefly the default ionic splashcreen appears, and then my correct one loads and then fades out correctly

I tested the app out on a completely new device and it didn’t load the old ionic splash screen at all like @Vigors said.

It must be something that the old splash screen is being cached in iOS before it’s overwritten with the new one!

Very frustrating after spending hours searching for that image file to find this is the reason!


#13

Yeh i find its working. I comment the “splashScreen.hide();” line in the app.component.ts.

Correct resource splash screen is shown on the app. Happy


#14

Ok I resolved the issue! I just need to manually delete the app from my phone and rerun from XCode.

As others have said, this probably due to a caching issue in ionic. I hope this helps someone else!


#15

None of the above suggestions have helped me. I’m still seeing my old Splash screen…


#16

I actually had to remove the splashScreen.hide() line and to delete the app from my phone and shutdown / restart my phone entirely to solve this.


#17

Its ok now, and I think this is what helped me as well.


#18

remove the ios platform:

ionic cordova platform remove ios

and then add the ios platform:

ionic cordova platform add ios

All plugins and resources will be regenerated and the problem will be solved.


#19

Finally i resolved with those images

resources/ios/splash/Default@2x~universal~anyany.png
resources/ios/splash/Default@3x~universal~anyany.png


#20

use this
< preference name=“ShowSplashScreenSpinner” value=“false”/>