Open Installed Pwa from External Url

Open installed PWA from external url

If you are using Chrome in Android or any of the desktop OS, that would be the default behavior.

Check on "Android intent filter" in this link.

This feature is not supported in iOS yet for PWA apps(created using Safari- the only option for iOS as of June-2018).See "What PWAs can do on Android and not on iOS" section last point.

Link to add external PWA to homepage

Your use case seems prone to abuse and has the potential to do serious damage both to your brand as well as the general perception of PWA's by your customers.

However, to answer your question, you could try using frames or iframes to achieve this. Here are the criteria to get the Add to Homescreen banner to show up:

  • The web app must not already be installed
  • Must meet a user engagement heuristic (currently, the user has interacted with the domain for at least 30 seconds)
  • Must have a web app manifest that includes:

    • short_name or name
    • icons must include a 192px and a 512px sized icons
    • start_url
    • display must be one of: fullscreen, standalone, or minimal-ui
  • Must be served over HTTPS (required for service workers)
  • Must have registered a service worker with a fetch event handler

When these criteria are met, Chrome will fire a beforeinstallprompt event that you can use to prompt the user to install your Progressive Web App.

Other browsers have different criteria for installation, or to trigger the beforeinstallprompt event.

Source:

https://developers.google.com/web/fundamentals/app-install-banners/



Related Topics



Leave a reply



Submit