strings.ContainsAny
Reports whether the given string contains any character within the given set.
- Syntax
- strings.ContainsAny STRING SET
- Returns
- bool
Usage
The strings.ContainsAny function reports whether the given string contains any character within the given set. The check is case-sensitive.
Examples
{{ strings.ContainsAny "Hugo" "gm" }} → true
{{ strings.ContainsAny "Hugo" "Gm" }} → falseLast updated:
October 28, 2026
:
content: Apply style guide to strings functions (d6de31ebd)
Improve this page