I am trying to add a splash screen in flutter instead of a blank white screen that shows on startup... I followed this youtube tutorial video. But unfortunately, this method is not working for me.
I added color and image location in android/app/src/main/res/drwable
<?xml version="1.0" encoding="utf-8"?>
<!-- Modify this file to customize your launch splash screen -->
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
<item android:drawable="@color/red" />
<!-- You can insert your own image assets here -->
<item>
<bitmap
android:gravity="center"
android:src="@drawable/randa" />
</item>
</layer-list>
and then I added color value in android/app/src/main/values/color.xml
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="red">#FF0000</color>
</resources>
Here is a screenshot - launch_background xml and color xml
As I am new in flutter development and I don't have much knowledge about XML.. any help will greatly be appreciated
Note- I tried every answer from google but nothing seems to be working for me. :-(