hugo/docs/content/en/functions/strings/RuneCount.md
2023-10-20 09:43:56 +02:00

655 B

title description categories keywords menu function relatedFunctions aliases
strings.RuneCount Returns the number of runes in a string.
functions
docs
parent
functions
aliases returnType signatures
int
strings.RuneCount INPUT
len
strings.Count
strings.CountRunes
strings.CountWords
strings.RuneCount
/functions/strings.runecount

In contrast with the strings.CountRunes function, which excludes whitespace, strings.RuneCount counts every rune in a string.

{{ "Hello, 世界" | strings.RuneCount }} → 9