{{ if .Site.Params.showLatest }}
Latest Post
{{ range first 1 (where .Data.Pages.ByPublishDate.Reverse "Section" "blog") }}
{{ .Date.Format (.Site.Params.dateform | default "Jan 02, 2006") }}
{{ end }}
{{ end }}
{{ if .Site.Params.showAllPosts }}
All Posts
{{ range .Data.Pages.ByPublishDate }}
{{ if eq .Section "blog" }}
{{ partial "li.html" . }}
{{ end }}
{{ end }}
{{ else }}
{{ end }}