MCPcopy
hub / github.com/continuedev/continue / toAsyncIterable

Function toAsyncIterable

packages/fetch/src/stream.ts:1–8  ·  view source on GitHub ↗
(
  nodeReadable: NodeJS.ReadableStream,
)

Source from the content-addressed store, hash-verified

1export async function* toAsyncIterable(
2 nodeReadable: NodeJS.ReadableStream,
3): AsyncGenerator<Uint8Array> {
4 for await (const chunk of nodeReadable) {
5 // @ts-ignore
6 yield chunk as Uint8Array;
7 }
8}
9
10export async function* streamResponse(
11 response: Response,

Callers 1

streamResponseFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected