Re: [w3c/ServiceWorker] windowClients state change events - loaded/unloaded (#1269)

I have some state that I would like to clean up when a client disappears. I was hoping to be able to use a `WeakMap` but it seems like the `WindowClient` instance of fetch events are all different references, making it impossible to use a `WeakMap` for this.

I guess polling is not too big of an issue since the user isn't likely to close tabs very frequently. But still, having an event to handle this case would be preferable.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/w3c/ServiceWorker/issues/1269#issuecomment-1374263294
You are receiving this because you are subscribed to this thread.

Message ID: <w3c/ServiceWorker/issues/1269/1374263294@github.com>

Received on Friday, 6 January 2023 23:39:41 UTC