EventEmitter for AssemblyScript
- No Dependencies
- Isomorphic
- Works in Nodejs/Browser/Wasmer
- Small code size
~ npm install as-events
import { EventEmitter } from 'as-events'
const emitter = new EventEmitter<string>()
emitter.on('event', (data) => {
//...
})
emitter.emit('event', 'Hello Event Emitter!')