The Javascript DataView getBigInt64() method gets a signed 64-bit integer at the specified byte offset from the DataView.
The return value is a BigInt.
dataview.getBigInt64(byteOffset [, littleEndian])
byteOffset
- the offset, in bytes, from the start of the view to read the data from.littleEndian
- Optional, indicates whether the 64-bit int is stored in little- or big-endian format. If false or undefined, a big-endian value is read.Using the getBigInt64 method
var buffer = new ArrayBuffer(8); var dataview = new DataView(buffer); let a = dataview.getBigInt64(0); console.log(a);