Skip to main content
isNull - util - Node documentation
function isNull

Usage in Deno

import { isNull } from "node:util";
isNull(object: unknown): object is null
Deprecated

Since v4.0.0 - Use value === null instead.

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