MCPcopy Create free account
hub / github.com/cloudflare/computer / transform

Function transform

packages/computer/src/backends/worker-javascript/frames.ts:55–58  ·  view source on GitHub ↗
(chunk, controller)

Source from the content-addressed store, hash-verified

53 return source.pipeThrough(
54 new TransformStream<Uint8Array, RuntimeFrame>({
55 transform(chunk, controller) {
56 buffer += decoder.decode(chunk, { stream: true });
57 drain(controller, false);
58 },
59 flush(controller) {
60 buffer += decoder.decode();
61 drain(controller, true);

Callers

nothing calls this directly

Calls 1

drainFunction · 0.70

Tested by

no test coverage detected