There are in fact two "Add to home screen" features on Android browsers:
The popup dialog that is automatically showed on the bottom of Chrome Android when specific conditions are met (
manifest.json
available, having a service worker as discussed here, website visited at least twice in > 5 minutes, etc.)The Chrome menu item that we can trigger for any website, even if it does not have a service worker. This one simply creates a shortcut to the website on the home screen of the mobile device:
Question: How to add a button on a HTML page that triggers the creation of a home screen shortcut, like in the second bullet before? (i.e. for a very simple HTML website, without any service worker)