replace .RawContent with .Summary - looks way better

.Summary retains all formatting of posts for the paginator which looks much nicer than .RawContent. The length of the .Summary (in words, not characters) can be set via the config variable summaryLength.
This commit is contained in:
Timo Ollech
2020-02-11 21:40:23 +01:00
committed by GitHub
parent 7b9ac34f10
commit 2dcf88303a

View File

@@ -19,10 +19,8 @@
<span class="description"> <span class="description">
{{ if isset .Params "description" }} {{ if isset .Params "description" }}
{{ .Description }} {{ .Description }}
{{ else if gt (len .RawContent) 120 }}
{{ slicestr .RawContent 0 120 }}...
{{ else }} {{ else }}
{{ .RawContent }} {{ .Summary }}&hellip;
{{ end }} {{ end }}
</span> </span>
</div> </div>