lin3s-event-bus
Version:
Simple but powerful event bus written in ES2015
40 lines (31 loc) • 1.42 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", {
value: true
});
var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
/*
* This file is part of the EventBusJS library.
*
* Copyright (c) 2016-present LIN3S <info@lin3s.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*
* @author Beñat Espiña <benatespina@gmail.com>
* @author Mikel Tuesta <mikeltuesta@gmail.com>
*/
var Event = function () {
function Event(aName) {
_classCallCheck(this, Event);
this.name = aName;
}
_createClass(Event, [{
key: "getName",
value: function getName() {
return this.name;
}
}]);
return Event;
}();
exports.default = Event;