Closed amandabaker closed 10 months ago
canInstall()
was more useful in previous ideations of the API. I agree there doesn't seem to be use case for this method nowadays, considering that the promise will fail if the website can't be installed. I am happy to remove this method from the explainer.
There is however, a need to use the inquire
field (https://github.com/MicrosoftEdge/MSEdgeExplainers/issues/681)? (not exactly the same use case though, but slightly more useful)
there is no need for a canInstall methos as the promise will resolve or reject accordingly.
As it's implemented now, I can't see a use case for
navigator.canInstall()
that works well considering that:The use cases that I've considered aren't compatible with those shortcomings:
canInstall()
check if each one is installable so that it can disable an install button for any apps that are not installablecanInstall()
to disable an install button if the app is not installable (essentially the same scenario, but just for one app)canInstall()
, it will take an unknown (and potentially inconsistent) amount of time to execute, which might lead to a bad user experience. Although Chromium is removing the service worker checks that were causing much of the cost and variability in installability checks, not all UAs have the same requirements, and they may change in the future.Additionally, the current implementation doesn't consider that an app store may want to know the difference between an app that is not installable due to missing installability criteria vs an app that is already installed.
Are there other use cases for this method or should it be removed?