Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/web3/types/bignumber.d.ts>BigNumber#isInteger

Deno / TypeScript to Ethereum Connector
Latest
method BigNumber.prototype.isInteger
import { BigNumber } from "https://deno.land/x/web3@v0.11.1/types/bignumber.d.ts";

Returns true if the value of this BigNumber is an integer, otherwise returns false.

x = new BigNumber(1)
x.isInteger()                   // true
y = new BigNumber(123.456)
y.isInteger()                   // false

Returns

boolean