Options
All
  • Public
  • Public/Protected
  • All
Menu

External module "IsLengthInRange"

Index

Functions

Functions

isLengthInRange

  • isLengthInRange(value: string, min: number, max?: number): boolean
  • Checks if the string's length falls in a range. Note: this function takes into account surrogate pairs. If given value is not a string, then it returns false.

    Parameters

    • value: string

      The value being checked.

    • min: number

      The min value to perform the check against.

    • Optional max: number

      The max value to perform the check against.

    Returns boolean

    True if the check passes, false otherwise.

Generated using TypeDoc