Home > rc-js-util > IBroadcastEvent
Simple one to many communication channel. Proxies the arguments of emit to each listener.
Signature:
export interface IBroadcastEvent<TKey extends string, TArgs extends unknown[]>
Method | Description |
---|---|
addListener(listener) | |
addOneTimeListener(listener) | Like addListener but unregisters after first event. |
addTemporaryListener(listener) | |
emit(args) | |
getTargets() | |
removeListener(listener) |