Problem building for Android: white screen after splashscreen

Hi,
after building my app for Android with this command:
ionic cordova build android --prod --release

and this configuration;

>ionic info

Ionic:

   ionic (Ionic CLI)  : 4.0.2 
   Ionic Framework    : ionic-angular 3.9.2
   @ionic/app-scripts : 3.1.11

Cordova:

   cordova (Cordova CLI) : 8.0.0
   Cordova Platforms     : android 7.1.1

System:

   Android SDK Tools: 26.1.1
   NodeJS            : v8.11.3 (C:\Program Files\nodejs\node.exe)
   npm               : 6.2.0

when I execute the app on a mobile I can see the splash screen, but after the splash screen, it shows a white screen instead of my app.
I think that I have this problem after updating Angular to the version 6.1.0.

If I build a brand new app it works well.
If I try the app using the command ionic serve -lcs and ā€œIonic Dev Appā€ I donā€™t have this problem.

I donā€™t know how to debug this problem because I have no errors, only a white screen.
Iā€™ve found some similar question in the forum, but they refer to previous versions of Ionic.

Thank you
cld

Do you get the same problem without --release and/or --prod?
Compare the dependencies of the newly created project with what you have - are you in the future? Some unsupported newer library?

Yes, I get the same problem without --release and/or --prod.

Iā€™m checking these dependencies.

But another strange things is that if I try to install the ā€œ.apkā€ I get this error: ā€œApp non installedā€.
According to a post found on Internet Iā€™ve used an Apk Editor to change the Installation Path.
After this modification the App starts, I can see the splash screen and after a white screen.

Could these problems be related?

cld

What does this mean?

Sorry, this was another problem discussed and solved in this thread in which I talk about a new brand app.

Here Iā€™m talking about an app with many customizations.
Installing and executing the file app-debug.apk on my phone, I still have a white page after the splash screen.
Iā€™ve also installed the same core dependencies of a newly created project and the problem still remains.

So the problem regards my customizations in the code or in some additional modules installed.

cld

At the end Iā€™ve created a new project and added the pages and the modules one at time.
Now it works.
The only files that change between the two versions of the app are

package.json
package-lock.json

The file package.json differs only for the line

-    "cordova-android": "7.1.1",
+   "cordova-android": "^7.1.1",

The file package-lock.json differs from many lines, it will be hard to understand which is the one that breaks the app.

1 Like

what versions is you create?

I have the same problem and I trying to fix it

>ionic info
āˆš Gathering environment info - done!

Ionic:

   ionic (Ionic CLI)  : 4.1.1
   Ionic Framework    : ionic-angular 3.9.2
   @ionic/app-scripts : 3.2.0

Cordova:

   cordova (Cordova CLI) : 8.0.0
   Cordova Platforms     : android 7.1.1
   Cordova Plugins       : cordova-plugin-ionic-keyboard 2.1.2, cordova-plugin-ionic-webview 2.1.0, (and 7 other plugins)

System:

   Android SDK Tools : 26.1.1 
   NodeJS            : v8.11.4 
   npm               : 6.4.0
   OS                : Windows 10

Iā€™ve not yet understood which was the library that caused the problem.