Re: [w3c/ServiceWorker] consider allowing a non-scope identifier for registrations (#1512)

> I don't think this is the right model. Calling register with a different script URL is altering one registration, whereas the scenario above is moving one registration and unregistering another.

I can make it reject for now and we can consider loosening it in the future.

I do worry a bit about some sharp edges for sites in the future with my pattern matching scopes work.  We want to support registrations with multiple scopes.  If a site is migrating from having two registrations to a single registration that covers both of the old scopes how do they reasonably do that migration?  It may be hard to ensure the timing of the registration/move of the final registration vs the removal of the old registration.  They certainly can't do it atomically.

Maybe we could consider adding a further `unregisterConflicts:true` option to register() that would opt-in to removing conflicting registrations automatically.

-- 
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/ServiceWorker/issues/1512#issuecomment-667159003

Received on Friday, 31 July 2020 14:50:16 UTC