Summary: Make it possible for web pages to do |new EventTarget|, and
more importantly to create EventTarget subclasses like |class MyThing
extends EventTarget| that can then have DOM events dispatched on them in
the normal way, have event listeners registered with all the features
browsers support (e.g. { once: true }), etc.
Bug: https://bugzilla.mozilla.org/show_bug.cgi?id=1379688
Spec: https://dom.spec.whatwg.org/#dom-eventtarget-eventtarget
Target release: 59
Preference behind which this is implemented: None.
Enabled in sandboxed iframes: Yes.
Devtools bug: I don't think devtools need to do anything special here.
Support in other browsers:
* Chrome: intent to ship thread is at
<https://groups.google.com/a/chromium.org/forum/#!topic/blink-dev/fKk4d_Vj080>
and the code landed (see
<https://bugs.chromium.org/p/chromium/issues/detail?id=740576>).
* Safari: no signals.
* Edge: no signals.
Tests: We have web platform tests for this.
Spec stability: Pretty stable. This is a very simple feature with a
simple spec, since it's just exposing an underlying well-specced and
well-tested primitive.
Security/privacy concerns: None that I know of.
Use cases: See summary.
Example use:
https://github.com/w3c/web-platform-tests/blob/b0efb74111af13f7abf3b3b1860667f98746b07f/dom/events/EventTarget-constructible.any.js#L27-L61
-Boris
_______________________________________________
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform