archive: add comments to more easily identify logic branches

This commit is contained in:
John Bowdre 2024-06-01 21:10:42 -05:00
parent 1c636f161d
commit f1eb781a58

View file

@ -19,6 +19,7 @@
{{- if eq .Kind "taxonomy" }}
{{- if eq .Title "Tags" }}
{{/* list of all tags */}}
<div class="tagsArchive">
{{- range $key, $value := .Site.Taxonomies }}
{{- $slicedTags := ($value.ByCount) }}
@ -30,6 +31,7 @@
{{- end }}
</div>
{{- else }}
{{/* list of all categories */}}
{{- range .Pages.ByDate.Reverse }}
{{- $postDate := .Date.Format "2006-01-02" }}
{{- $updateDate := .Lastmod.Format "2006-01-02" }}
@ -49,6 +51,7 @@
{{- end }}
{{- else }}
{{- if eq .Title "/slashes" }}
{{/* slash page archive */}}
{{- $sortedSlashes := sort $pages "Title" }}
{{- range $sortedSlashes }}
{{- $postDate := .Date.Format "2006-01-02" }}
@ -67,6 +70,7 @@
</article>
{{- end }}
{{- else }}
{{/* regular posts archive */}}
{{- range (.Paginate $pages).Pages }}
{{- $postDate := .Date.Format "2006-01-02" }}
{{- $updateDate := .Lastmod.Format "2006-01-02" }}