1.0.1 ā¢ Published 2 years ago
observer-emit v1.0.1
observer-emit
š A Node.js event emitter works in the browser.
Install
using npm
$ npm i observer-emit
using yarn
$ yarn add observer-emit
using pnpm
$ pnpm i observer-emit
Usage
import observer from 'observer-emit'
observer.on('asuka', () => console.log('asuka', 1))
observer.on('nagi', () => console.log('nagi'))
observer.off('asuka')
observer.on('asuka', () => console.log('asuka', 2))
observer.emit('asuka') // asuka 2
observer.emit('nagi') // nagi
observer.once('ume', () => console.log('ume'))
observer.emit('ume') // ume
observer.emit('ume')
observer.emit('ume')
License
MIT License Ā© 2022 Akashi Sai
1.0.1
2 years ago
1.0.0
2 years ago
0.0.6-beta.1
2 years ago
0.0.5-beta.3
2 years ago
0.0.5-beta.2
2 years ago
0.0.5-beta.0
2 years ago
0.0.6
2 years ago
0.0.5
2 years ago
0.0.4
2 years ago
0.0.3
2 years ago
0.0.2
2 years ago
0.0.1
2 years ago
0.0.0
2 years ago