Re: [w3c/manifest] Add a unique identifier for a PWA (#586)

> The strawman I had been thinking of was something lile:
> ```
> navigator.serviceWorker.register('sw.js', {
>   scope: '/some/scope',
>   token: 'my-origin-unique-token',
> });
> ```
A couple of thoughts:

1. I would find it odd if a _web_ application was identified by anything other than a Uniform Resource Identifier. Apart from being what makes the web the web, URIs make great origin-unique tokens! I would hope there's no need to invent another type of ID namespace like Play Store/App Store style app IDs.
2. What's the latest thinking on the mapping between a service worker and an app?

It would be really neat if there was a 1:1 mapping between the two and app scope == service worker scope, then you could use the manifest URI as the unique identifier for both and update both navigation scope and service worker scope together in a single update. (There [used to be](https://github.com/w3c/manifest/pull/825) a similar kind of mapping in the manifest, but the other way around.)

But my understanding is that isn't the case and it's currently possible to have multiple service workers per app or multiple apps per service worker, or have one and not the other. If the two technologies are entirely de-coupled then maybe they have to have their own mechanisms for identifying an installed application vs. an installed service worker.

-- 
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/586#issuecomment-608552441

Received on Friday, 3 April 2020 17:01:07 UTC