{{ range .Data.Pages }} {{if eq .Type "index" }}
{{.Content}}
{{end}} {{ end }} {{ if not ($.Scratch.Get "paginatedSections") }} {{ if .Site.Params.paginatedsections }} {{ $.Scratch.Set "paginatedSections" .Site.Params.paginatedsections }} {{ else }} {{ $.Scratch.Set "paginatedSections" "post" }} {{ end }} {{ end }} {{ $list := .Site.RegularPages }} {{ $paginator := .Paginate ( $list ) }}
{{ partial "pagination.html" $paginator }}
{{ range $index, $page := $paginator.Pages }} {{ partial "li.html" . }} {{ end }} {{ partial "pagination.html" $paginator }}