UNPKG

@100mslive/hms-video-store

Version:

@100mslive Core SDK which abstracts the complexities of webRTC while providing a reactive store for data management with a unidirectional data flow

14 lines (13 loc) 637 B
import type { WaitForFilter } from 'eventemitter2'; import { EventEmitter2 as EventEmitter } from 'eventemitter2'; export declare class HMSInternalEvent<T> { private eventName; private eventEmitter; constructor(eventName: string, eventEmitter: EventEmitter); publish: (event?: T) => void; subscribe: (fn: (event: T) => void | Promise<void>) => void; subscribeOnce: (fn: (event: T) => void | Promise<void>) => void; unsubscribe: (fn: (event: T) => void | Promise<void>) => void; waitFor: (predicate: WaitForFilter) => import("eventemitter2").CancelablePromise<any[]>; removeAllListeners: () => void; }