HomeAbout

Array Buffer

What is ArrayBuffer

JS object used to represent a generic raw binary data.

  • fixed length container for binary data.

You cannot directly manipulate the contents of an ArrayBuffer.

Instead, you need to create one of the typed array objects or a DataView object which represents the buffer in a specific format.

  • you can use that object to read and write the contents of the buffer.

You can also get an array buffer from existing data, for example, from a Base64 string or from a local file.

const buffer = new ArrayBuffer(8); // buffer const view = new Int32Array(buffer); // creating a typed array view of the buffer
AboutContact