commit 448f0306d79c32089ad148e131063b6fb836454e
parent 02d2f05e7455f12ee4598af6fef2346180d2abfd
Author: Hanchen Wang <hanchen.wang@mail.utoronto.ca>
Date: Wed, 11 May 2016 10:16:44 -0400
docs: Example of how to use Order by ExpiryDate
Diffstat:
1 file changed, 9 insertions(+), 0 deletions(-)
diff --git a/docs/content/templates/list.md b/docs/content/templates/list.md
@@ -187,6 +187,15 @@ your list templates:
<div class="meta">{{ .PublishDate.Format "Mon, Jan 2, 2006" }}</div>
</li>
{{ end }}
+
+### Order by ExpiryDate
+
+ {{ range .Data.Pages.ByExpiryDate }}
+ <li>
+ <a href="{{ .Permalink }}">{{ .Title }}</a>
+ <div class="meta">{{ .ExpiryDate.Format "Mon, Jan 2, 2006" }}</div>
+ </li>
+ {{ end }}
### Order by Lastmod