diff --git a/layouts/section/post.html b/layouts/post/list.html similarity index 53% rename from layouts/section/post.html rename to layouts/post/list.html index 3acc693..a662ac2 100644 --- a/layouts/section/post.html +++ b/layouts/post/list.html @@ -1,12 +1,17 @@ {{ define "main" }} +{{/* + This template is the same as the default and is here to demonstrate that if you have a content directory called "post" you can create a layouts directory, just for that section. + */}}
{{ .Content }}
- {{ $section := .Paginate (where .Data.Pages "Section" .Section) }}
- {{ range $section.Pages }} + {{ range .Pages }}
+ {{/* + Note we can use `.Render` here for items just in this section, instead of a partial to pull in items for the list page. https://gohugo.io/functions/render/ + */}} {{ .Render "summary" }}
{{ end }}