event-target-shim icon indicating copy to clipboard operation
event-target-shim copied to clipboard

Support for CustomEvent

Open oles opened this issue 4 years ago • 1 comments

As a curiosity, I'd like to experiment with the native variant of an event emitter, as described in

https://medium.com/@zandaqo/eventtarget-the-future-of-javascript-event-systems-205ae32f5e6b and https://css-tricks.com/lets-create-a-lightweight-native-event-bus-in-javascript/

It works in all modern browsers today and Deno - but not Node!

Running new CustomEvent() results in ReferenceError: CustomEvent is not defined in the latest version (currently 15.5.1)

I'm not sure if it's in scope for this project to support it, or if a custom-event-shim is more fitting :thinking:

oles avatar Jan 12 '21 20:01 oles

Thank you for your proposition.

Indeed, sounds good that this package provides CustomEvent as well.

mysticatea avatar Feb 02 '21 08:02 mysticatea