| 1 |
--- |
| 2 |
title: strings.ContainsAny |
| 3 |
description: Reports whether the given string contains any character within the given set. |
| 4 |
categories: [] |
| 5 |
keywords: [] |
| 6 |
params: |
| 7 |
functions_and_methods: |
| 8 |
aliases: [] |
| 9 |
returnType: bool |
| 10 |
signatures: [strings.ContainsAny STRING SET] |
| 11 |
aliases: [/functions/strings.containsany] |
| 12 |
--- |
| 13 |
|
| 14 |
```go-html-template |
| 15 |
{{ strings.ContainsAny "Hugo" "gm" }} → true |
| 16 |
``` |
| 17 |
|
| 18 |
The check is case sensitive: |
| 19 |
|
| 20 |
```go-html-template |
| 21 |
{{ strings.ContainsAny "Hugo" "Gm" }} → false |
| 22 |
``` |