Re: [whatwg/dom] [Proposal] Add EventTarget.getEventListeners() (#412)

For example, given [the code for TacoButton here](https://html.spec.whatwg.org/multipage/scripting.html#custom-elements-autonomous-drawbacks), you'd no longer be able to guarantee that all taco-buttons on the page properly forward enter/space keydowns to click events, or that they stop firing click events when disabled. Being unable to reason about your program in this way is a real burden, and it changes your story as a component author from "include my component and it'll work" to "include my component but make sure all your third-party scripts aren't doing some over-aggressive cleanup action or you'll see strange behavior".

I still lean toward exposing the functionality, and then you'll just have to accept that you can no longer write encapsulated components in that way, but I think it's a real tradeoff between two different types of developer convenience, not one between theoretical purity and developer convenience.

-- 
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/412#issuecomment-280694952

Received on Friday, 17 February 2017 16:21:08 UTC