Re: [whatwg/dom] Owned weak event listener to prevent memory leak (using EventListenerOptions) (#243)

I think developers should avoid event target outliving its event listeners where possible, no matter SPA or not. If not possible, try owned weak event listener :). If all failed, I think it means the app is not modulized well.

I think `owner` can be changed by call `addEventListener()` again with a different `owner`. Per spec, only `capture` of `EventListenerOptions` affects the identity of event listener.

>when that owner can be implied already by querying parentNode or similar?
How? The event target and event listener don't  known the logical owner of the event listener unless we specify one.

---
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/dom/issues/243#issuecomment-217886005

Received on Monday, 9 May 2016 14:50:01 UTC