A lightweight event dispatcher.
$ npm install --save @hellomonday/emitter
import Emitter from '@hellomonday/emitter';
const emitter = new Emitter();
// listen to an event
emitter.on(EVENTS.scroll, this.onScroll);
// stop listening to an event
emitter.off(EVENTS.scroll, this.onScroll);
// emit an event
emitter.emit(EVENTS.scroll, {position: 100});
MIT © Hello Monday