import type { RpcChannel } from "./RpcChannel.js"; /** * Convert any thrown value into the wire-safe `{ code, message, stack }` shape. * * Fixes the "[object Object]" bug: the old code did `err?.message || String(err)`, * so an error with an EMPTY message (e.g. a backend error `{ code, message: '' }`) * fell through to `String(obj)` → "[object Object]". We now never stringify the * object blindly — we surface its real fields (code/name, JSON of own props) so * the main thread receives something legible. Always returns a structured-clone * safe plain object, so postMessage can't throw DataCloneError on a class error. */ export declare function serializeError(err: any): { code: string; message: string; stack?: string; }; export declare class WorkerManager { #private; private channel; constructor(channel: RpcChannel); exposeService(name: string, service: any): void; } //# sourceMappingURL=WorkerManager.d.ts.map