Skip to content

PAIO-CO-KR/mediator-module

Repository files navigation

mediator-module NPM version Build Status Dependency Status Coverage percentage

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.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published