feat: add support for tags ordering

This commit is contained in:
Kazhnuz Klappsthul 2023-07-29 15:37:38 +02:00
parent 2bf6ffece9
commit ac0d2a49c9
2 changed files with 2 additions and 2 deletions

View File

@ -27,7 +27,7 @@ layout: layouts/parent.njk
<div class="card">
<h2>{{ tag }}</h2>
<ul>
{%- for post in collections[tag] -%}
{%- for post in collections[tag] | sort(false, true, "data.order") -%}
<li><a href="{{ post.url }}">{{ post.data.title }}</a></li>
{%- endfor -%}
</ul>

View File

@ -27,7 +27,7 @@ layout: layouts/parent.njk
<div class="card">
<h2>{{ tag }}</h2>
<ul>
{%- for post in collections[tag] -%}
{%- for post in collections[tag]-%}
<li><a href="{{ post.url }}">{{ post.data.title }}</a></li>
{%- endfor -%}
</ul>