Skip to main content

Convert a ReadableStream to an array of chunks

还没翻译译自英文(bun.com)本页 3 段都还没译

Bun.readableStreamToArray reads the contents of a ReadableStream into an array of chunks.

const stream = new ReadableStream();
const chunks = await Bun.readableStreamToArray(stream);

See Bun's other ReadableStream conversion functions.

번역 © 2026 fanyi.dev · 원문 © 2026 the Bun project (LICENSE.md names no copyright holder) (MIT)