-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
strings.HasPrefix already has an alias of hasPrefix but strings.HasSuffix has no such alias. This PR adds a hasSuffix alias to the tpl function with corresponding function documentation. It also adds a Minor update to the hasPrefix function documentation re: keywords and relatedfuncs. Completes gohugoio/hugo#10474
- Loading branch information
Showing
2 changed files
with
23 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
--- | ||
title: hassuffix | ||
linktitle: hasSuffix | ||
description: Tests whether a string ends with suffix. | ||
date: 2023-03-01 | ||
publishdate: 2023-03-01 | ||
lastmod: 2023-03-01 | ||
categories: [functions] | ||
menu: | ||
docs: | ||
parent: "functions" | ||
keywords: [strings] | ||
signature: ["hasSuffix STRING SUFFIX"] | ||
workson: [] | ||
hugoversion: | ||
relatedfuncs: [hasPrefix] | ||
deprecated: false | ||
aliases: [] | ||
--- | ||
|
||
* `{{ hasSuffix "Hugo" "go" }}` → true |