mirror of
https://github.com/gohugoio/hugoDocs.git
synced 2025-08-20 21:11:58 -04:00
Fix the order of arguments to strings.TrimRight
This commit is contained in:
parent
f1f9b7cd63
commit
0982f65c15
@ -20,9 +20,9 @@ aliases: []
|
||||
|
||||
Given the string `"abba"`, trailing `"a"`'s can be removed a follows:
|
||||
|
||||
{{ strings.TrimRight "abba" "a" }} → "abb"
|
||||
{{ strings.TrimRight "a" "abba" }} → "abb"
|
||||
|
||||
Numbers can be handled as well:
|
||||
|
||||
{{ strings.TrimRight 1221 "12" }} → ""
|
||||
{{ strings.TrimRight 12 1221341221 }} → "122134"
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user