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

16 lines (15 loc) 488 B
export interface DataChannelObserver { onMessage(value: string): void; } export default class HMSDataChannel { private readonly TAG; private readonly nativeChannel; private readonly observer; private readonly metadata; get id(): number | null; get label(): string; get readyState(): RTCDataChannelState; constructor(nativeChannel: RTCDataChannel, observer: DataChannelObserver, metadata?: string); send(message: string): void; close(): void; }