x-event

    1.0.0 • Public • Published

    Event

    Event is a JavaScript library providing observer pattern implementation.

    Examples

    var Event = require('x-event');
     
    var myEvent = new Event();
    myEvent.addListener(function(message) {
        console.log(message);
    });
    myEvent.notifyListeners('my message');

    Method aliases

    addListener - add, subscribe.
    removeListener - remove, unsubscribe.
    notifyListeners - emit, publish, trigger.
    

    Installation

    npm install --save x-event

    Install

    npm i x-event

    DownloadsWeekly Downloads

    1

    Version

    1.0.0

    License

    MIT

    Last publish

    Collaborators

    • lexarx