effect-io-ai

Package: effect
Module: BigInt

BigInt.isLessThanOrEqualTo

Returns a function that checks if a given bigint is less than or equal to the provided one.

When to use

Use to test whether one bigint is less than or equal to another.

Example (Checking less-than-or-equal comparisons)

import { BigInt } from "effect"
import * as assert from "node:assert"

assert.deepStrictEqual(BigInt.isLessThanOrEqualTo(2n, 3n), true)
assert.deepStrictEqual(BigInt.isLessThanOrEqualTo(3n, 3n), true)
assert.deepStrictEqual(BigInt.isLessThanOrEqualTo(4n, 3n), false)

Signature

declare const isLessThanOrEqualTo: { (that: bigint): (self: bigint) => boolean; (self: bigint, that: bigint): boolean; }

Source

Since v4.0.0