GoogleChromeLabs / GoogleChromeLabs/bubblewrap
Information/Dialog Fallback
- Dominant language
- TypeScript
- Stars
- 3.1k
- Forks
- 319
- PR merge metrics
- No merged PRs in 30d
Description
**Is your feature request related to a problem? Please describe.**
For some users without a compatible browser, we would like to be able to inform the user that their setup is not compatible, as the app requires e.g. Google Chrome or another compatible browser.
This is caused by neither of the currently available fallback methods providing a sufficient user experience as is, providing the users with a subpar experience without communicating to them that they can very easily improve the experience.
This seems to be related to the issues described in #549 ([specifically the follow-up comment](https://github.com/GoogleChromeLabs/bubblewrap/issues/549#issuecomment-862780564)):
> I'm wondering if it would be possible to check if a TWA compatible browser is installed from the PlayStore and if not display a note saying "this app requires Chrome" or something, or not let the user install it at all, like when the app is not listed in your country?
In some cases, neither of the currently available fallback methods is fitting.
**Describe the solution you'd like**
I would like to provide the user with an informative dialog as a fallback, in cases where the developer deems none of the fallback alternatives to be sufficient.
A minimum would be something like a "not-supported"/"none"-fallback type, preferably with a "fallback-text"-property:
```json
{
...
"fallbackType": "not-supported",
"fallbackHeader": "Compatible Web Browser Required",
"fallbackText": "This application requires a compatible browser, such as Google Chrome (> 72.0) or Microsoft Edge (> 45.05)",
...
}
```
**Describe alternatives you've considered**
We have considered opening a WebView-fallback and have it open a URL where we can attempt to detect that it is open in a WebView and from there inform the user of the missing browser.
However, this is not a very nice workaround and is error prone.
We have not attempted to actually implement this, it is simply the closest alternative that comes to mind.
I will post another issue to request ability to append the user-agent for the WebView-fallback which would make this easier to implement.
**Edit:** This is now issue #925
**Additional context**
Sample of the requested dialog:

Contributor guide
Assessment
This issue has not been assessed yet.