next-event
Call a function the next time a specific event is emitted
npm install next-event
Basically like .once
but faster.
Usage
var nextEvent =var ontest =emitteremitter
Note that only the last function you pass to ontest
in the above example
will be called when the next event is emitted
emitter
API
var once = nextEvent(emitter, name)
Create a new once function. Pass an event handler to once
that should be called the next time name
is emitted.
License
MIT