I got a splash screen issue on Android app which is ejected, and the current SDK is 36.
And here is my issue, when I open the app, it will show the splash screen correctly, which is from my drawable/splash_background.xml
(I will call drawable/splash_background.xml
splash screen) :
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
<item android:drawable="@color/splashBackground"/>
<item><bitmap android:gravity="center" android:src="@drawable/shell_launch_background_image" /></item>
</layer-list>
and the splash screen lasts 2 seconds, then the screen becomes blank for 5 seconds and enters the main screen after that. I did some research, so I changed the SHOW_LOADING_VIEW_IN_SHELL_APP
from false to true in android/app/src/main/java/host/exp/exponent/generated/AppConstants.java
, now it is showing a stretched image screen instead of the blank screen. So I believe the app is downloading javascript bundle.
I also tried in some different ways:
-
I used
@drawable/shell_notification_icon.png
instead of@drawable/shell_launch_background_image
===> the splash screen is replaced by the notification icon, but the stretched image is sill the old one. -
I replaced
@drawable/shell_launch_background_image
with a big resolution image, a totally different image
===> both splash screen and stretched image screen remain the same, where exactly are they from since I have changed the source image -
I changed
image
value, fromsplash
property inapp.json
===> the stretched images didn’t change. -
I removed all the
splash
property fromapp.json
,
===> splash screen keeps the same, but next screen becomes expo image
I am getting very confused, I upgraded from SDK 35, it was working without any issue. Does anyone have ideas about this?
Thanks