Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Intent to Implement and Ship: AddEventListenerOptions.once

54 views
Skip to first unread message

Xidorn Quan

unread,
Jul 20, 2016, 8:54:18 AM7/20/16
to dev-pl...@lists.mozilla.org
Summary:

"once" is a new option for EventTarget.addEventListener (as a member of
AddEventListenerOptions dictionary), which means that the added listener
should only be invoked once. It is something libraries like jQuery have
been providing for years. And it would make writing certain type of
tests much easier.

Bug: https://bugzilla.mozilla.org/show_bug.cgi?id=1287706

Link to standard:
https://dom.spec.whatwg.org/#dom-addeventlisteneroptions-once

Platform coverage: all

Estimated or target release: Firefox 50 or 51

Preference behind which this will be implemented: no pref. It is a small
feature which I don't think needs a pref.

DevTools bug: Not filed yet. DevTools may want to display whether an
event listener is a once listener.


- Xidorn


signature.asc

smaug

unread,
Jul 20, 2016, 1:11:54 PM7/20/16
to Xidorn Quan
+1


For Devtools nsIEventListenerInfo need to be updated.
0 new messages