API reference › @evolu/common › BigInt › isBetweenBigInt
function isBetweenBigInt(min: bigint, max: bigint): Predicate<bigint>;
Defined in: packages/common/src/BigInt.ts:33
Creates a predicate that checks if a BigInt is within a range, inclusive.
Example
const isBetween10And20 = isBetweenBigInt(10n, 20n);
console.log(isBetween10And20(15n)); // true
console.log(isBetween10And20(25n)); // false