ixfx
    Preparing search index...

    Function integerTest

    • Checks if value an integer and meets additional criteria. See numberTest for guard details, or use that if integer checking is not required.

      Note:

      • bipolar will mean -1, 0 or 1.
      • positive: must be at least zero
      • negative: must be zero or lower
      • aboveZero: must be above zero
      • belowZero: must be below zero
      • percentage: must be within 0-1, inclusive
      • nonZero: can be anything except zero

      Parameters

      • value: undefined | number

        Value to check

      • range: NumberGuardRange = ...

        Guard specifier.

      • parameterName: string = ...

        Param name for customising exception message

      Returns GuardResult