session-signal
v1.0.4
Published
Emit a signal at end of desired session (UTC)
Downloads
22
Readme
session-signal
Emit a signal at end of desired session (UTC)
Install
npm install session-signal
Use
import SessionSignal from 'session-signal'
let sessionEmitter = new SessionSignal(['1', '5', '15', '1H']).getEmitter()
sessionEmitter.on('newSession', ISR)
function ISR(sessions: number[]) {
console.log('New session!', new Date(), sessions)
}