strings.HasPrefix

将以下英文翻译为中文:

strings.HasPrefix

https://gohugo.io/functions/strings.hasprefix/

Tests whether a string begins with prefix.

语法

hasPrefix STRING PREFIX
strings.HasPrefix STRING PREFIX
{{ hasPrefix "Hugo" "Hu" }} → true

另请参阅