mirror of
https://github.com/gohugoio/hugoDocs.git
synced 2025-09-11 17:07:24 -04:00
Fix a typo in templates docs
This commit is contained in:
parent
09ff1f27c4
commit
c9551d4337
@ -179,15 +179,15 @@ Within a template action you may [pipe] a value to function or method. The piped
|
|||||||
You can pipe the result of one function or method into another. For example, these are equivalent:
|
You can pipe the result of one function or method into another. For example, these are equivalent:
|
||||||
|
|
||||||
```go-html-template
|
```go-html-template
|
||||||
{{ strings.TrimSuffix "o" (strings.ToLower "Hugo") }} → Hug
|
{{ strings.TrimSuffix "o" (strings.ToLower "Hugo") }} → hug
|
||||||
{{ "Hugo" | strings.ToLower | strings.TrimSuffix "o" }} → Hug
|
{{ "Hugo" | strings.ToLower | strings.TrimSuffix "o" }} → hug
|
||||||
```
|
```
|
||||||
|
|
||||||
These are also equivalent:
|
These are also equivalent:
|
||||||
|
|
||||||
```go-html-template
|
```go-html-template
|
||||||
{{ mul 6 (add 2 5) }} → 42
|
{{ mul 6 (add 2 5) }} → 42
|
||||||
{{ 2 | add 5 | mul 6 }} → 42
|
{{ 5 | add 2 | mul 6 }} → 42
|
||||||
```
|
```
|
||||||
|
|
||||||
{{% note %}}
|
{{% note %}}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user