Search code examples
splash-screenprogressive-web-apps

Is it possible to configure delay into a PWA splash screen?


I am developing a PWA following google recommendations and my splash screen is showing correctly after user has added it to their home screen.

I wonder if there is any way to configure some custom delay time the splash screen should show. I need to set a minimum 2˜3 seconds delay so the user can see the company logo in it. Sometimes it shows and expires very fast like 200ms, and sometimes it shows up to 10 seconds, i just want to set a minimum time. Is it possible? Didn't find any reference on PWA's documentation...

One thing i've tried is to set a "second" splash screen but this is not good in cases where the native splash screen lasts up to 10 seconds, then it shows my custom splash screen again (bad user experience)...

This is my manifest.json:

{
  "name": "Some application",
  "short_name": "Sa",
  "lang": "pt-BR",
  "start_url": "/",
  "display": "standalone",
  "theme_color": "#FFFFFF",
  "icons": [
    {
      "src": "assets/icons/192x192.png",
      "sizes": "192x192"
    }
  ],
  "background_color": "#FFFFFF"
}

Solution

  • I've found out that this feature is not possible yet, but there are several discussions on this subject happening, like this one below. Apperently some improvements on how you can customize the splash screen are being tested for over a year: https://github.com/w3c/manifest/issues/589#issuecomment-323232119