import CustomEvents from 'tui-code-snippet/customEvents/customEvents'; import type { AnyFunc } from "../types/eventBus"; export interface EventBus { on(eventName: EventName, handler: EventTypes[EventName]): EventBus; off(eventName?: EventName, handler?: EventTypes[EventName]): EventBus; once(eventName: EventName, handler: EventTypes[EventName]): EventBus; fire(eventName: EventName, ...args: Parameters): EventBus; } export declare class EventBusImpl extends CustomEvents implements EventBus { on(eventName: EventName, handler: EventTypes[EventName]): this; off(eventName?: EventName, handler?: EventTypes[EventName]): this; fire(eventName: EventName, ...args: Parameters): this; once(eventName: EventName, handler: EventTypes[EventName]): this; }