Signature
path=null start=null
Parameters
- str:
string- The string to truncate. - maxLength:
number- The maximum length of the string after truncation.
Returns
string - The truncated string, or the original string if it was shorter than the maximum length.