MCPcopy
hub / github.com/simstudioai/sim / streamFromStringChunks

Function streamFromStringChunks

apps/sim/lib/core/utils/sse.test.ts:321–324  ·  view source on GitHub ↗
(chunks: string[])

Source from the content-addressed store, hash-verified

319})
320
321function streamFromStringChunks(chunks: string[]): ReadableStream<Uint8Array> {
322 const encoder = new TextEncoder()
323 return createStreamFromChunks(chunks.map((c) => encoder.encode(c)))
324}
325
326describe('readSSEEvents', () => {
327 it('parses `\\n\\n`-framed events', async () => {

Callers 1

sse.test.tsFile · 0.85

Calls 1

createStreamFromChunksFunction · 0.85

Tested by

no test coverage detected