import { InternalMessage } from './types';
export declare type ListenerFunction<S> = (message: InternalMessage, sender: S) => void;
declare type ActorKey = 'content' | 'context' | 'background' | 'worker';
export interface ListenerConfig<S> {
    listenFrom: Set<ActorKey>;
    onMessage: ListenerFunction<S>;
    thisActor: ActorKey;
    worker?: Worker;
}
export declare function listen<S>(config: ListenerConfig<S>): void;
export {};
