UNPKG

typescript-event-emitter

Version:

Versatile and feature-rich TypeScript library for event management, providing a solid foundation for building event-driven applications in TypeScript.

14 lines (13 loc) 587 B
import { OnDestroy } from '@angular/core'; import { Observable } from 'rxjs'; import { Option } from './../../index'; interface EventSource { on(event: string, listener: (eventName: string, payload: any) => void, options?: Option): void; off(event: string, listener: (eventName: string, payload: any) => void): void; } export declare class BaseEventService implements OnDestroy { protected subscriptions: Array<() => void>; protected fromEventSource<T = unknown>(source: EventSource, event: string, options?: Option): Observable<T>; ngOnDestroy(): void; } export {};