- From: Oliver Dunk <notifications@github.com>
- Date: Mon, 08 Jan 2024 05:00:09 -0800
- To: w3c/ServiceWorker <ServiceWorker@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
Received on Monday, 8 January 2024 13:00:15 UTC
Thanks for opening this Jackie. As we discussed in the last WECG meeting, I think improving extension events is something everyone is supportive of longer term and very curious to see if any web folk have thoughts on how we can make things more ergonomic. That said, I'm not sure if this proposal is the right one: - What does `subscribe` do that `addListener` doesn't? You mention that it would remember the function, but I think we could do this with `addListener` as well. I'm reluctant to add a new subscription method without compelling reason. - We're making the assumption here that it is feasible for browsers to remember functions long-term (and that developers would be ok with this) which I think would need extra validation. I'd prefer to look at ways of using `self.addEventListener` in extension service workers for extension events to align with the web. And then once we've got there, we can find potential improvements to registration. -- Reply to this email directly or view it on GitHub: https://github.com/w3c/ServiceWorker/issues/1698#issuecomment-1880961855 You are receiving this because you are subscribed to this thread. Message ID: <w3c/ServiceWorker/issues/1698/1880961855@github.com>
Received on Monday, 8 January 2024 13:00:15 UTC