UNPKG

@liturgical-calendar/components-js

Version:

Liturgical calendar components for javascript: an html select populated with liturgical calendars supported by the Liturgical Calendar API; form controls for parameters that are supported by the Liturgical Calendar API; a webcalendar; and liturgy of the d

26 lines 928 B
export default class EventEmitter { /** * Adds a listener for the specified event. * * @param {string} event - The event to listen for. * @param {function} listener - The listener to invoke when the event occurs. */ on(event: string, listener: Function): void; /** * Emits a specified event, invoking all registered listeners with the provided data. * * @param {string} event - The name of the event to emit. * @param {*} data - The data to pass to each event listener. */ emit(event: string, data: any): void; /** * @type {Object<string, Array<function>>} * @returns {Object<string, Array<function>>} a shallow copy of the object containing all registered events and their respective listeners * @readonly */ readonly get _events(): { [x: string]: Function[]; }; #private; } //# sourceMappingURL=EventEmitter.d.ts.map