type EventListener = (payload: unknown) => void | Promise; declare class EventBus { constructor(); private readonly listeners; on(event: string, listener: EventListener): () => void; listen(event: string, listener: EventListener): () => void; emit(event: string, payload: unknown): Promise; dispatch(event: string, payload: unknown): Promise; } declare function readSharedEventBus(): EventBus; declare const eventBus: EventBus; export type { EventListener }; export { EventBus, eventBus, readSharedEventBus };