We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
This new proposal adds .on method to EventTarget, then we can control event handling using Observable API.
.on
EventTarget
Example from the spec:
// Filtering and mapping: element .on('click') .filter((e) => e.target.matches('.foo')) .map((e) => ({ x: e.clientX, y: e.clientY })) .subscribe({ next: handleClickAtPoint });
Spec: https://github.com/WICG/Observable Standard Tracking: WICG/observable#93
This is something that makes sense to implement on Node?
Basically implements the new .on method at:
node/lib/internal/event_target.js
Line 551 in a0ac8bd
The @benlesh (contributor of the spec) looks like he already tried to implement this new spec at #51065
The text was updated successfully, but these errors were encountered:
Successfully merging a pull request may close this issue.
What is the problem this feature will solve?
This new proposal adds
.on
method toEventTarget
, then we can control event handling using Observable API.Example from the spec:
Spec: https://github.com/WICG/Observable
Standard Tracking: WICG/observable#93
This is something that makes sense to implement on Node?
What is the feature you are proposing to solve the problem?
Basically implements the new
.on
method at:node/lib/internal/event_target.js
Line 551 in a0ac8bd
What alternatives have you considered?
The @benlesh (contributor of the spec) looks like he already tried to implement this new spec at #51065
The text was updated successfully, but these errors were encountered: