Skip to main content
isNumberObject - util/types - Node documentation
function isNumberObject

Usage in Deno

import { isNumberObject } from "node:util/types";
isNumberObject(object: unknown): object is Number

Returns true if the value is a number object, e.g. created by new Number().

util.types.isNumberObject(0);  // Returns false
util.types.isNumberObject(new Number(0));   // Returns true

Parameters

object: unknown

Return Type

object is Number
Back to top