If a DataView contains ASCII-encoded text, use the TextDecoder class to convert it to a string.
const dv: DataView = ...;
const decoder = new TextDecoder();
const str = decoder.decode(dv);
See Binary Data.
Runtime docs · Guides · Binary Data
Decode the bytes of a DataView into a string with the Web-standard TextDecoder.
If a DataView contains ASCII-encoded text, use the TextDecoder class to convert it to a string.
const dv: DataView = ...;
const decoder = new TextDecoder();
const str = decoder.decode(dv);
See Binary Data.