• Split a string into substrings using the specified separator and return them as an array.

    Parameters

    • separator: string | RegExp

      A string that identifies character or characters to use in separating the string. If omitted, a single-element array containing the entire string is returned.

    • Optional limit: number

      A value used to limit the number of elements returned in the array.

    Returns string[]

  • Split a string into substrings using the specified separator and return them as an array.

    Parameters

    • splitter: {
          [split](string, limit?): string[];
      }

      An object that can split a string.

      • [split]:function
        • Parameters

          • string: string
          • Optional limit: number

          Returns string[]

    • Optional limit: number

      A value used to limit the number of elements returned in the array.

    Returns string[]

Generated using TypeDoc