The isarraybuffer
function from the Underscore library checks whether a given value is an ArrayBuffer object or not. Here's an example of how to use it:
index.tsx342 chars13 lines
In the above example, we first import the Underscore library using the require()
function. We then create an ArrayBuffer object and store it in the buffer
variable. We use the isArrayBuffer()
function from Underscore to check whether the buffer
object is an ArrayBuffer or not. Finally, we log the result to the console.
gistlibby LogSnag