0

I created custom splash screen. and check with cache data and api data inside custom splash screen. if existing user available move to home page and if not move to login page. But When the app open showing white black screen(native splash screen) and then showing my custom splash screen.

Is it possible to remove it without editing native code(adding image or something, like Adding a splash screen to Flutter apps)?

BIS Tech
  • 17,000
  • 12
  • 99
  • 148
  • [this](https://flutter.dev/docs/development/ui/assets-and-images#updating-the-launch-screen) is the official way, whats wrong with it? – pskink Nov 21 '19 at 07:04
  • You can use the official way like @pskink's link refers and add your custom splash screen as well. If both UI remains exactly the same, user won't experience the difference and you can have your logic at that custom screen. – Farwa Nov 21 '19 at 07:07
  • it's meaning before the app starting, running two pages. right? native splash screen and my splash screen? – BIS Tech Nov 21 '19 at 07:16
  • [updating-the-launch-screen](https://flutter.dev/docs/development/ui/assets-and-images#updating-the-launch-screen) - this is the official way, did you try it? – pskink Nov 21 '19 at 08:06
  • yes, I tried... – BIS Tech Nov 21 '19 at 08:07
  • I added color to a native splash screen and then load my custom splash screen and then load home or login page... but why load two splash screen? – BIS Tech Nov 21 '19 at 08:11
  • I added cường-nguyễn way..it's working on android..is there way to do it like on ios? – BIS Tech Nov 21 '19 at 08:11

1 Answers1

1

With Android: You can add two lines to app/res/values/styles.xml

<item name="android:windowDisablePreview">true</item>
<item name="android:windowIsTranslucent">true</item>

enter image description here

Cuong Nguyen
  • 970
  • 6
  • 17