Skip to main content
The Blob class provides several methods for consuming its contents in different formats. Read the contents into an ArrayBuffer with .arrayBuffer(), then create a Uint8Array from the buffer.
const blob = new Blob(["hello world"]);
const arr = new Uint8Array(await blob.arrayBuffer());

See Binary Data.