API reference > @kontsedal/olas-cross-tab > ChannelLike
ChannelLike type
Tiny BroadcastChannel-shaped abstraction. Lets tests inject a fake (a shared in-memory bus across multiple "tabs" in the same process) and keeps server safety in one place: outside a browser, and with nochannelFactory override, the plugin opens no channel and installs no hooks.
Signature:
typescript
type ChannelLike = {
postMessage(data: unknown): void;
addEventListener(type: 'message', listener: (event: {
data: unknown;
}) => void): void;
removeEventListener(type: 'message', listener: (event: {
data: unknown;
}) => void): void;
close(): void;
};