isBufferRaw

external fun isBufferRaw(value: Any?): Boolean(source)

Returns true if the given object is a Buffer. Otherwise, returns false.

const util = require('node:util');

util.isBuffer({ length: 0 });
// Returns: false
util.isBuffer([]);
// Returns: false
util.isBuffer(Buffer.from('hello world'));
// Returns: true

Since

v0.11.5