Function isBigInt

  • Checks if a given value is of bigint type.

    Example

    isBigInt(10n)
    // => true

    isBigInt(BigInt(Number.MAX_SAFE_INTEGER))
    // => true

    isBigInt(hello)
    // => false

    Type Parameters

    • T extends bigint

      The expected type of the value.

    Parameters

    • value: unknown

      The value to be checked.

    Returns value is T

    true if the given value is of bigint type, false otherwise.

Generated using TypeDoc v0.24.7