Re: [push-api] Technique to Detect Endpoint Prior to register() (#95)

Yes theoretically a UA could have a setting for the preferred push service to use. So UA sniffing is not 100% correct. Certainly the same browser is likely to use different services on different platforms, so a platform check would be required when performing UA sniffing.

Agreed that there is no good solution for this yet:
* You could try to enumerate all possible services in the spec and expose the one in use, but that's not reasonable as the list is likely to grow.
* You could expose a service identifier as a DOMString for which the content is not specified. But that is still a bit sad because it enshrines forward incompatibility as part of the API: any new service would go unrecognized and not work until the site and service registration are updated.

What we really need is to either make advance registration with the service unnecessary, or coordinate some kind of universal registration across services, which needs to be performed only once.

---
Reply to this email directly or view it on GitHub:
https://github.com/w3c/push-api/issues/95#issuecomment-67002039

Received on Monday, 15 December 2014 14:35:32 UTC