mirror of
https://github.com/sbrow/thor.git
synced 2026-08-26 11:23:32 -04:00
feat(mustache): Added group_by filter to templates
This commit is contained in:
@@ -3,17 +3,17 @@
|
||||
<main>
|
||||
<h1>{{page_title}}</h1>
|
||||
{{&body}}
|
||||
{{#by_year}}
|
||||
{{#posts | group_by year}}
|
||||
<section>
|
||||
<h2>{{year}}</h2>
|
||||
<h2>{{key}}</h2>
|
||||
<ul>
|
||||
{{#posts}} <li><a href="{{permalink}}">{{&title}}</a><span>{{#date_iso}}<time
|
||||
{{#items}} <li><a href="{{permalink}}">{{&title}}</a><span>{{#date_iso}}<time
|
||||
datetime="{{date_iso}}">{{date_display}}</time>{{/date_iso}}</span>
|
||||
</li>
|
||||
{{/posts}}
|
||||
{{/items}}
|
||||
</ul>
|
||||
</section>
|
||||
{{/by_year}}
|
||||
{{/posts}}
|
||||
</main>
|
||||
{{/content}}
|
||||
{{/base}}
|
||||
|
||||
Reference in New Issue
Block a user