DEV Community

Discussion on: Write your own chainable Event Emitter class for Node and Browser

Collapse
 
justintime4tea profile image
Justin Gross • Edited

Anyone working with event emitters that support wild cards here's a friendly heads up. Don't listen to wild card and in the callback emit any events without some matching on the event... :) Callstack could explode. Be sure to factor in a matcher of sorts which ignores your own emitted messages if emitting from within the wild card callback!