White screen while opening my ionic app in some devices

481 Views Asked by At

In few mobiles,my ionic app shows white screen only, when apk build with --prod mode. But the same apk works on other mobiles. If i build without --prod , it is working in all mobiles. i don't have any idea. Please help me out. Thanks in advance.

1

There are 1 best solutions below

3
AziDev On

If you are using android platform version 10.0.0 or higher. Then you have to remove whitelist plugin, if it is installed in your project. It doesn't work with android 10 or later. This is the reason it shows white screen after opening installed application.

cordova plugin rm cordova-plugin-whitelist
cordova prepare   OR ionic cordova prepare

if prepare doesn't work try to remove platform and add again.

ionic cordova platform rm android
ionic cordova platform add android

Thanks, Hope it helps you.