Release mode app shows white screen while debug mode app runs just fine


#1

I have a strange problem with my app. My app works fine in debug mode. But when I build it for release mode and for deployment after signing it with the certificate it shows white screen after splash screen. Can anyone help me with this issue. I observed logcats with adb which are same in both cases. No issue with that.


#2

make the duration of splashscreen longer(5 seconds) or if doesn’t fix add this in your platform ready:

setTimeout(function () {
            navigator.splashscreen.hide();
        }, 100);

#3

Hi,

I had the same issue and struggled to solved it.
In my case I created the release build with “ionic build --release” but got blank screen when opening the app after the splash because somehow the app wasn’t finding some files from a library.
I managed to solve this by building the app with cordova following the steps here:
https://cordova.apache.org/docs/en/latest/guide/platforms/android/index.html

you need to create a build.json file(in your base folder) where you configure your signing key and execute the command:
cordova build android --release – buildConfig
This generates the signed apk ready for release.

I hope it works good luck.


#4

Hi @mihair, I did the same thing you mentioned in your comments. But, still I am getting the white screen when opening the app after the splash.