take Or Cut
Returns a string containing the first n characters from this string + 3-bytes character …, or the entire string if the string is shorter.
Example:
"Hello world".takeOrCut(6) // "Hello…"
"Hello world".takeOrCut(5, countDots = false) // "Hello…"Content copied to clipboard
Parameters
Throws
if n is negative.