Cannot add launch_screen.png
See original GitHub issueRun react-native info
in your project and share the content.
OS: macOS 11.4
CPU: (8) x64 Apple M1
Memory: 35.50 MB / 8.00 GB
Shell: 3.2.57 - /bin/bash
Binaries:
Node: 12.4.0 - ~/.nvm/versions/node/v12.4.0/bin/node
Yarn: 1.22.10 - /usr/local/bin/yarn
npm: 7.19.1 - ~/.nvm/versions/node/v12.4.0/bin/npm
Watchman: 4.9.0 - /usr/local/bin/watchman
SDKs:
iOS SDK:
Platforms: iOS 14.4, DriverKit 20.2, macOS 11.1, tvOS 14.3, watchOS 7.2
Android SDK:
API Levels: 22, 23, 25, 26, 27, 28, 29, 30
Build Tools: 28.0.3, 29.0.1, 29.0.2, 29.0.3, 31.0.0
Android NDK: 17.2.4988734
IDEs:
Android Studio: 4.1 AI-201.8743.12.41.7042882
Xcode: 12.4/12D4e - /usr/bin/xcodebuild
npmPackages:
react: 16.9.0 => 16.9.0
react-native:0.61.5
npmGlobalPackages:
react-native-cli: 2.0.1
What react-native-splash-screen
version are you using?
The newest version.
What platform does your issue occur on? (Android/iOS/Both)
Android
Describe your issue as precisely as possible
I followed the guide customming lauch_screen.png but my app show white screen.
"Customize your launch screen by creating a launch_screen.png-file and placing it in an appropriate drawable-folder. Android automatically scales drawable, so you do not necessarily need to provide images for all phone densities. You can create splash screens in the following folders:
drawable-ldpi drawable-mdpi drawable-hdpi drawable-xhdpi drawable-xxhdpi drawable-xxxhdpi"
Issue Analytics
- State:
- Created 2 years ago
- Comments:8 (1 by maintainers)
you also can add this for IOS if you add current code to Dynamic.swift file, to func createAnimationView
for Android the right way you need add in launch_screen -
in my code this looks like
just changing android:background=“@color/white” to android:background=“@drawable/launch_screen” in your code. And add launch_screen.png to drawable folders