From: JinGen Lim Date: Sun, 1 Oct 2017 03:26:37 +0000 (+0800) Subject: Implement Content Summaries / Split on index page X-Git-Url: https://njoseph.me/gitweb/hyde.git/commitdiff_plain/b469743f16f9084951a2ba7a875b31b30e1213c9 Implement Content Summaries / Split on index page Posts in the index page will be automatically summarized to its first 70 words, or until a user-defined divider. When summarized, the "Read More" button also appears with a RelPermalink to the full post. https://gohugo.io/content-management/summaries/ --- diff --git a/layouts/index.html b/layouts/index.html index 3fed5be..209009e 100644 --- a/layouts/index.html +++ b/layouts/index.html @@ -6,7 +6,12 @@ {{ .Title }} {{ .Date.Format "Mon, Jan 2, 2006" }} - {{ .Content }} + {{ .Summary }} + {{ if .Truncated }} + + {{ end }} {{- end }}