0

I am currently working on a project that is ejected to Expokit and some weeks ago we upgraded SDK version from 32 to SDK 36, and since then, in Android devices, the Splash Screen from configuration options in app.json is not showing up anymore.

What we see first is the Splash image from splash_background.xml that is showing properly and after that everything we see is the color of backgroundColor from app.json.

The only thing that takes the changes is the backgroundColor inside the splash object (app.json). Also we are using AppLoading from expo, but changing or removing it doesn't affect anything.

This is happening just on Android, otherwise on iOS devices everything looks pretty good.

Environment

    - "react": "~16.9.0",
    - "react-native": "0.61.4",
    - "expo": "~36.0.0",
    - "expokit": "36.0.0",

app.json

    "sdkVersion": "36.0.0",
    "androidStatusBarColor": "#002C61",
    "androidStatusBar": {},
    "splash": {
      "image": "./assets/images/splash.png",
      "resizeMode": "cover",
      "backgroundColor": "#bc0229"
    },

splash_background.xml

    <?xml version="1.0" encoding="utf-8"?>enter code here
    <layer-list xmlns:android="http://schemas.android.com/apk/res/android">

        <item android:drawable="@color/splashBackground"/>

        <item><bitmap android:gravity="center" android:src="@drawable/splash" /></item>

    </layer-list>

2 Answers2

1

Using adb logcat with my device on (expo bare workflow) I had:

W OpenGLRenderer: Bitmap too large to be uploaded into a texture (2484x4672, max=4096x4096)

So I tried resizing down my splashscreen_image.png... and it worked.

0

What happens if you replace this line:

<item><bitmap android:gravity="center" android:src="@drawable/splash" /></item>

With this:

<item android:drawable="@drawable/splash" android:gravity="center"/>

I had an issue with some bitmaps not displaying recently and this post helped.

Code on the Rocks
  • 11,488
  • 3
  • 53
  • 61
  • Thanks for the answer. I tried this solution but didn't make any impact on the splash screen display. Maybe it is a bug on SDK36, because I think i have tried most of the solutions. – Besim Sallahi Feb 12 '20 at 09:39