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

641 B

title description categories keywords menu function relatedFunctions aliases
strings.ContainsAny Reports whether a string contains any character from a given string.
functions
docs
parent
functions
aliases returnType signatures
bool
strings.ContainsAny STRING CHARACTERS
strings.Contains
strings.ContainsAny
strings.ContainsNonSpace
strings.HasPrefix
strings.HasSuffix
/functions/strings.containsany
{{ strings.ContainsAny "Hugo" "gm" }} → true

The check is case sensitive:

{{ strings.ContainsAny "Hugo" "Gm" }} → false