{{ $pages := .Pages }} {{ if .IsHome }} {{ $pages = where site.RegularPages "Type" "in" site.Params.mainSections }} {{ end }}
{{ if .IsHome }}

{{ site.Params.indexTitle | markdownify }}

{{ else }} {{ if eq .Title "/slashes" }}

{{ .Title | markdownify }}

My collection of slash pages.
{{ else }}

{{ .Title | markdownify }}{{ if eq .Kind "term" }}  

{{ with .Description }}{{ . }}{{ end }} {{ end }}
{{ end }}{{ end }} {{ .Content }}
{{- if and (eq .Kind "taxonomy") (eq .Title "Tags") }} {{/* /tags/ */}}
{{- range $key, $value := .Site.Taxonomies }} {{- $slicedTags := ($value.ByCount) }} {{- range $slicedTags }} {{- if eq $key "tags"}}
{{ .Name }}{{ .Count }}
{{- end }} {{- end }} {{- end }}
{{- else if or (eq .Kind "taxonomy") (eq .Title "/slashes") }} {{/* /categories/ or /slashes/ */}} {{- $sorted := sort $pages "Title" }} {{- range $sorted }} {{- $postDate := .Date.Format "2006-01-02" }} {{- $updateDate := .Lastmod.Format "2006-01-02" }}

{{ .Title | markdownify }}

{{ .Description }}

{{ end }} {{- else }} {{/* regular posts archive */}} {{- range (.Paginate $pages).Pages }} {{- $postDate := .Date.Format "2006-01-02" }} {{- $updateDate := .Lastmod.Format "2006-01-02" }}

{{ .Title | markdownify }}

{{if .Description }}{{ .Description }}{{ else }}{{ .Summary }}{{ end }}

{{- end }} {{- template "_internal/pagination.html" . }} {{- end }}