> ## Documentation Index
> Fetch the complete documentation index at: https://bun.zhcndoc.com/llms.txt
> Use this file to discover all available pages before exploring further.

# 将 ReadableStream 转换为 Blob

Bun 提供了几个便捷函数，可将 [`ReadableStream`](https://developer.mozilla.org/en-US/docs/Web/API/ReadableStream) 的内容读取为不同格式。

```ts theme={"theme":{"light":"github-light","dark":"dracula"}}
const stream = new ReadableStream();
const blob = await Bun.readableStreamToBlob(stream);
```

***

请参阅 [文档 > API > Utils](/runtime/utils#bun-readablestreamto) 了解 Bun 其他 `ReadableStream` 转换函数的文档。
