{{ define "main" }} {{ $hasToc := and (in .TableOfContents "
  • " ) (.Params.toc) }} {{ $hasSidebar := or ($hasToc) (.Params.series) }}

    {{ .Title }}

    {{ partial "components/post-metadata" . }} {{ $featured := partial "utils/get-featured" . }} {{ with $featured }}
    {{ . }}
    {{ end }}
    {{ .Content}}
    {{ with .GetTerms "tags" }} {{ partial "components/post-tags" . }} {{ end }} {{ if or .Site.Params.repoURL .Site.Params.repoEditURL }} {{ partial "components/post-edit" . }} {{ end }} {{ with .GetTerms "authors" }} {{ partial "components/post-author" . }} {{ end }} {{ partial "components/post-footer" . }} {{ partial "comment.html" . }}
    {{ if $hasSidebar}}
    {{ if .GetTerms "series" }} {{ partial "components/post-series" . }} {{ end }} {{ if $hasToc }} {{ partial "components/post-toc" . }} {{ end }}
    {{ end }} {{ $related := .Site.RegularPages.Related . | first 6 }} {{ with $related }}

    {{ i18n "seeAlso" }}

    {{ range . }} {{ .LinkTitle }}
    {{ end }}
    {{ end }}
    {{ end }}