Normalize binary input to a plain Uint8Array backed by an ArrayBuffer.
Uint8Array
ArrayBuffer
Returns the input itself when it is already a plain Uint8Array over an ArrayBuffer, otherwise a fresh view (or, for SharedArrayBuffer-backed input, a copy) over the same bytes.
SharedArrayBuffer
Throws if input is not a recognised binary type.
Normalize binary input to a plain
Uint8Arraybacked by anArrayBuffer.Returns the input itself when it is already a plain
Uint8Arrayover anArrayBuffer, otherwise a fresh view (or, forSharedArrayBuffer-backed input, a copy) over the same bytes.Throws if input is not a recognised binary type.