diff --git a/i18n/en.yaml b/i18n/en.yaml index 0e6ecac..1dc5370 100644 --- a/i18n/en.yaml +++ b/i18n/en.yaml @@ -1,4 +1,7 @@ # Post +- id: post_toc + translation: Table of Contents + - id: meta_lastmod translation: Updated diff --git a/layouts/_default/single.html b/layouts/_default/single.html index 4830b53..286c290 100644 --- a/layouts/_default/single.html +++ b/layouts/_default/single.html @@ -5,6 +5,12 @@ {{- partial "post_thumbnail.html" (dict "page" . ) }}
{{ partial "post_meta.html" . }}

{{ .Title }}

+ {{ if eq .Params.toc true }} +
+ {{- T "post_toc" -}} + {{ .TableOfContents }} +
+ {{ end }}
{{ .Content }}