Re: [w3c/ServiceWorker] A way to immediately unregister a service worker (#614)

Good question. In our implementation Clear() has some logic to try to ensure the timing of events match the spec (when you see statechange, you see registration.active is null) which I felt could be possibly error-prone in ForceDelete() which is an emergency "GET ME OUT OF HERE" operation. That's where I was coming from with that comment.

I do think it'd be worth adding this operation in the spec. The spec currently doesn't allow the .controller to go from populated to null, which we do here in ForceDelete() and I believe we should also do for Clear-Site-Data and browser UI like "Clear Browsing Data".

-- 
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/614#issuecomment-501523285

Received on Thursday, 13 June 2019 02:22:54 UTC