Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/zwbetz-gh/cayman-hugo-theme.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorzwbetz <zwbetz@gmail.com>2019-08-17 00:04:49 +0300
committerzwbetz <zwbetz@gmail.com>2019-08-17 00:04:49 +0300
commitc5c1915d3d2a69bda61860f3a7846f6601540292 (patch)
tree911d4a787febe91fb4f91176b46b15799571855f /layouts
parent276b73d7cf1f4006c8ff1152c9f37a64a9ca8625 (diff)
fix issue per https://github.com/gohugoio/hugoThemes/issues/682
Diffstat (limited to 'layouts')
-rw-r--r--layouts/partials/blog-post-list.html3
1 files changed, 2 insertions, 1 deletions
diff --git a/layouts/partials/blog-post-list.html b/layouts/partials/blog-post-list.html
index afc39fd..55e69b5 100644
--- a/layouts/partials/blog-post-list.html
+++ b/layouts/partials/blog-post-list.html
@@ -1,6 +1,7 @@
<h1>{{ .Title }}</h1>
<ul>
-{{ range where site.RegularPages "Type" "in" site.Params.mainSections }}
+{{ $pages := where site.RegularPages "Type" "in" site.Params.mainSections }}
+{{ range $pages.ByPublishDate.Reverse }}
<li>
{{ $dateFormat := $.Site.Params.dateFormat | default "Jan 2, 2006" }}
{{ .PublishDate.Format $dateFormat }}