shithub: hugo

Download patch

ref: 4502c4e3aeb459a2df101eebdd76ad4318f812b0
parent: fe929114d3f34fe1999cd3cacd7f61c0ee0c0a54
author: digitalcraftsman <[email protected]>
date: Sat Apr 2 20:44:25 EDT 2016

docs: Add documentation for hasPrefix template func

Fixes #2039

--- a/docs/content/templates/functions.md
+++ b/docs/content/templates/functions.md
@@ -610,6 +610,12 @@
 * `{{substr "BatMan" 0 -3}}` → "Bat"
 * `{{substr "BatMan" 3 3}}` → "Man"
 
+### hasPrefix
+
+HasPrefix tests whether a string begins with prefix.
+
+* `{{ hasPrefix "Hugo" "Hu" }}` → true
+
 ### title
 Converts all characters in string to titlecase.