vision-embedded-web
Version:
Cubic Vision methods for embedded web content.
18 lines (17 loc) • 667 B
TypeScript
import { LiteAutoBind } from './lite-auto-bind';
export interface ISubscribeLiteEvent<T> {
on(handler: (data: T) => void): () => void;
off(handler: (data: T) => void): void;
once(handler: (data: T) => void): () => void;
}
export declare function createLiteEvent<T>(): LiteEvent<T>;
export default class LiteEvent<T> extends LiteAutoBind implements ISubscribeLiteEvent<T> {
private handlers;
private onceHandlers;
on(handler: (data: T) => void): () => void;
off(handler: (data: T) => void): void;
private execute;
emit(data: T): void;
once(handler: (data: T) => void): () => void;
unsubscribeAll(): void;
}