{{ $context := . }} {{- if .Params.contents -}}
{{- range $index, $content := .Params.contents -}} {{ if eq .kind "block" }} {{ $template := printf "blocks/templates/%s.html" $content.template }} {{ partial $template (dict "block" $content "context" $context "index" $index )}} {{- else if (eq .kind "heading") -}} {{ $headingId := .slug | default (urlize .title) }}

{{ partial "PrepareHTML" .title }}

{{- end -}} {{- end -}}
{{- end -}}