0.0.5 • Published 8 years ago
mediator-module v0.0.5
mediator-module
mediator module
Install
$ npm install --save mediator-module
Usage
var MediatorModule = require('mediator-module');
class FirstMediatorModule extends MediatorModule {
constructor () {
super();
this.mediator.subscribe('test', this.aTestFunction);
}
*aTestFunction () {
console.log('a func called');
}
}
class SecondMediatorModule extends MediatorModule {
constructor () {
super();
}
testPublish () {
this.mediator.publish('test');
}
}
License
MIT © PAIO co.,ltd.