Correct code example for index template function

typo in example code {{ index .Site.Data.locations .Params.location }}
This commit is contained in:
Sean Shao 2017-09-19 21:33:25 +08:00 committed by digitalcraftsman
parent bfa6a55d03
commit c8f1a2d2f6

View File

@ -71,7 +71,7 @@ This is where the `index` function is needed. `index` takes 2 parameters in this
The variable for `.Params.location` is a string and can therefore replace `oslo` in the example above:
```
{{ index .Site.Data.authors .Params.author }}
{{ index .Site.Data.locations .Params.location }}
=> map[website:https://www.oslo.kommune.no pop_city:658390 pop_metro:1717900]
```