Skip to main content
function isNull
isNull(object: unknown): object is null
Deprecated

Returns true if the given object is strictly null. Otherwise, returnsfalse.

import util from 'node:util';

util.isNull(0);
// Returns: false
util.isNull(undefined);
// Returns: false
util.isNull(null);
// Returns: true

Parameters

object: unknown

Return Type

object is null
Back to top