nanolith
Version:
Multi-threading in no time with seamless TypeScript support.
11 lines (10 loc) • 391 B
TypeScript
import type { MessengerList as MessengerListType } from '../types/messenger.js';
/**
* An object containing functions to be used within workers when interacting with {@link Messenger}s.
*
* @example
* const messenger = await MessengerList.use('foo');
*
* messenger.onMessage<string>((data) => console.log(data, 'received!'));
*/
export declare const MessengerList: MessengerListType;