Skip to content

ByteSink

type ByteSink = object;

Defined in: src/wire/writer.ts:198

A browser/worker-friendly byte sink: write receives each fully-serialized chunk of response bytes (a schema msg, a batch, or the EOS marker) and must deliver them in order. Used by the in-browser SAB (worker:) transport, which has no Node fd/Socket — the sink writes into the worker→client ring.

write: (bytes) => void | Promise<void>;

Defined in: src/wire/writer.ts:200

Deliver one fully-serialized chunk of response bytes, in order.

Parameter Type
bytes Uint8Array

void | Promise<void>