rembrembdocs

Skip to main content

Bun home pagelight logodark logo

[Runtime

](../../../index.md)[Package Manager

](../../../pm/cli/install/index.md)[Bundler

](../../../bundler/index.md)[Test Runner

](../../../test/index.md)[Guides

](../../index.md)[Reference

](https://bun.com/reference)[Blog

](https://bun.com/blog)[Feedback

](../../../feedback/index.md)

If a DataView contains ASCII-encoded text, you can convert it to a string using the TextDecoder class.

const dv: DataView = ...;
const decoder = new TextDecoder();
const str = decoder.decode(dv);

See Docs > API > Binary Data for complete documentation on manipulating binary data with Bun.

Was this page helpful?

Suggest editsRaise issue

[

Convert a Uint8Array to a ReadableStream

Previous

](../typedarray-to-readablestream/index.md)[

Convert a ReadableStream to a string

Next

](../../streams/to-string/index.md)