eventemitter-decorator

0.1.2 • Public • Published

EventEmitterDecorator

build status npm version

USAGE

import EventEmitter from 'eventemitter-decorator';
 
@EventEmitter
class Foo {}
 
const foo = new Foo();
foo.on('hello', (name) => console.log(`hello, ${name}!!`));
 
foo.emit('hello', 'world');  // 'hello, world!!'

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.1.2
    1
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 0.1.2
    1
  • 0.1.1
    0
  • 0.1.0
    0

Package Sidebar

Install

npm i eventemitter-decorator

Weekly Downloads

1

Version

0.1.2

License

MIT

Last publish

Collaborators

  • fand