This function mirrors the length property from the JavaScript Standard String object. It counts
grapheme clusters instead of UTF-16 code units. Since length appears to be a reserved keyword,
the function was renamed to stringLength.
Counts as a literate reader of the script would, including for pointed Hebrew, vocalized Arabic
and Syriac, Indic conjuncts, Thai, and decomposed Hangul Jamo. \r\n counts as one.
This function mirrors the
lengthproperty from the JavaScript Standard String object. It counts grapheme clusters instead of UTF-16 code units. Sincelengthappears to be a reserved keyword, the function was renamed tostringLength.Counts as a literate reader of the script would, including for pointed Hebrew, vocalized Arabic and Syriac, Indic conjuncts, Thai, and decomposed Hangul Jamo.
\r\ncounts as one.