Re: [w3c/manifest] Allowing only site-triggered install prompt (#627)

**Today's situation:** a broken user experience; on some devices users will see an "add" (they are afraid of using "install") prompt sometimes (based on beforeinstallprompt), on some other devices, there is no prompt. Designers are creating UA-dependant floating dialogs and screenshots or animations to show the user how to "install" the app based on the current browser and OS. Therefore, users might not understand what's going on, or how an app can be installed and we are back to techniques based on UA sniffing. I think this is a current issue for the Web App Manifest "installation".

**What to expect**: The experience should be more consistent between platforms and let the web content offer an install button is actually the good idea. Users don't have a "store" to install these web/apps, so the UA is the store. While we can't force UAs to use a consistent UI for a native installation, we can offer web developers an API to request that behavior from a consistent UI within the boundaries of the website's canvas, if they want to.

I agree that the installation dialog should only be available when some conditions are met, both from user interaction and requirements from the site. Also, following some ideas recently implemented for Web Push permission dialog, if the user rejects or dismisses the dialog, UA can remove support for the API for that origin for an amount of time to promote authors to use it with responsibility. Suggesting a non-modal dialog sounds like a good idea.

I'm not sure though if the install() method should also have some optional or mandatory checks that can be made to be sure the icon/app is not already installed. It might be an optional attribute, a different interface or a different API, such as in:

`navigator.checkIfInstalled().then( installed => if (!installed) navigator.install() );
`
I'm not sure if there is currently a definition for a key value for an "installed webapp", such as the Manifest URL; Android is currently [experimenting](https://www.chromestatus.com/feature/5695378309513216) with this thanks to WebAPK installation, but it's a side effect of a different API, not something part of the Manifest spec.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/manifest/issues/627#issuecomment-381688540

Received on Monday, 16 April 2018 17:42:09 UTC