Search code examples
androidprogressive-web-appssamsung-mobiletrusted-web-activity

TWA Fullscreen PWA for Chrome and Samsung Internet


I'm trying to turn my PWA (Progressive web Application) into an TWA (Trusted Web Acitivity) App for Android. In the beginning everything was working fine, until a user reported a problem to me.

He was unable to open the App at all, so we checked to see what could be the cause. Turns out he hasn't installed Google Chrome and is using Samsung Internet instead.

Now I did manage to get the App working with Samsung Internet so far, but with Samsung Internet the address-bar still appears.

There are a few tutorials to setup your TWA for Chrome OR Samsung Internet, but how can I combine these two? I guess we shouldn't force the user to download Chrome first. I haven't found any articles concerning this issue, so I'd be grateful if someone can link me some.


Solution

  • After tons of wasted time trying to figure this out myself and lots of research I found this article: https://medium.com/@firt/google-play-store-now-open-for-progressive-web-apps-ec6f3c6ff3cc

    Where you can find this info:

    TWAs work only with Chrome today, but the API might be also cloned by other browsers, such as Samsung Internet, Edge or Firefox in the future.

    *UPDATE 2/4: The TWA works over the Android Custom Tab protocol that other browsers are currently implementing, so if the user doesn’t have Chrome or has changed the default browser, another browser might take precedence and open the TWA with the PWA content. More testing is needed to understand how it works. What happens if the user has an older version of Chrome and installs the app from the Play Store? In this case, your PWA will appear as a Chrome Custom Tab, not in a completely standalone mode.

    What that means in a nutshell: TWA's are actually useless, as long as you need your App to be compatible with a lot of different devices (like most do). I also noticed many Apps don't work if you disable Chrome on your Device, why I guess these are using TWA's too (and getting bad reviews on PlayStore instead).

    So what I did was to dump away everything I did with TWA, and simply started using Cordova instead. It would have been great to have something like TWA's working just that simple, but as long as it's not working without having Chrome installed, there's no point in using it at all.

    And not having this stated on https://developers.google.com directly, but fuzzy and unclear, has probably ended in the waste of time of many dev's and/or tons of Users being unable to use some Apps.