diff options
Diffstat (limited to 'layouts')
| -rw-r--r-- | layouts/_default/home.wordstats.json | 11 | ||||
| -rw-r--r-- | layouts/_default/single.html | 2 |
2 files changed, 12 insertions, 1 deletions
diff --git a/layouts/_default/home.wordstats.json b/layouts/_default/home.wordstats.json new file mode 100644 index 0000000..b227510 --- /dev/null +++ b/layouts/_default/home.wordstats.json @@ -0,0 +1,11 @@ +[ +{{- $pages := where site.RegularPages "Section" "posts" -}} +{{- $first := true -}} +{{- range $pages -}} +{{- if not .Draft -}} +{{- if not $first }},{{ end -}} +{"title":{{ .Title | jsonify }},"wordCount":{{ .WordCount }}} +{{- $first = false -}} +{{- end -}} +{{- end -}} +] diff --git a/layouts/_default/single.html b/layouts/_default/single.html index 271ddd8..d20343b 100644 --- a/layouts/_default/single.html +++ b/layouts/_default/single.html @@ -7,7 +7,7 @@ <div class="meta"> {{/* Publish date */}} <time datetime="{{ .PublishDate }}" title='{{ .PublishDate.Format "Mon, Jan 2, 2006, 3:04 PM MST" }}'> - {{ .PublishDate.Format "02/01/2006" }} - Estimated reading time: {{ .ReadingTime }} minutes + {{ .PublishDate.Format "02/01/2006" }} - {{ .WordCount }} words - Estimated reading time: {{ .ReadingTime }} minutes </time> {{/* Categories */}} |
