Function trimSuffix

  • remove suffix from string

    Parameters

    • str: string

      to be processed string

    • suffix: string

      string

    Returns string

    Since

    5.5.0

    See

    [[trimPrefix]]

    trimSuffix("123456789", "789")
    // => '123456'