isObject

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

Returns true if the given object is strictly an Objectand not aFunction (even though functions are objects in JavaScript). Otherwise, returns false.

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

util.isObject(5);
// Returns: false
util.isObject(null);
// Returns: false
util.isObject({});
// Returns: true
util.isObject(() => {});
// Returns: false

Since

v0.11.5