Asset.prototype.arrayBuffer

Return an ArrayBuffer containing the contents of the asset.

Syntax

arrayBuffer()

Return value

An ArrayBuffer.

If the asset is too big to fit in an array buffer, an error is thrown. In this case, use blob(), reader() or lines() to read its contents.

Examples

Asset("myasset").arrayBuffer()
ArrayBuffer [ 0, 1, 2, 3, 4, 5, 6, 7 ]