39 lines
994 B
HTML
39 lines
994 B
HTML
|
---
|
||
|
layout: default
|
||
|
nocard: true
|
||
|
title: Tags
|
||
|
---
|
||
|
{% assign rawtags = "" %}
|
||
|
{% for post in site.posts %}
|
||
|
{% assign ttags = post.tags | join:'|' | append:'|' %}
|
||
|
{% assign rawtags = rawtags | append:ttags %}
|
||
|
{% endfor %}
|
||
|
{% assign rawtags = rawtags | split:'|' | sort %}
|
||
|
|
||
|
{% assign tags = "" %}
|
||
|
{% for tag in rawtags %}
|
||
|
{% if tag != "" %}
|
||
|
{% if tags == "" %}
|
||
|
{% assign tags = tag | split:'|' %}
|
||
|
{% endif %}
|
||
|
{% unless tags contains tag %}
|
||
|
{% assign tags = tags | join:'|' | append:'|' | append:tag | split:'|' %}
|
||
|
{% endunless %}
|
||
|
{% endif %}
|
||
|
{% endfor %}
|
||
|
|
||
|
{% for tag in tags %}
|
||
|
<div class="card">
|
||
|
<h2 id="{{ tag | slugify }}">{{ tag }}</h2>
|
||
|
<div class="collection">
|
||
|
{% for post in site.posts %}
|
||
|
{% if post.tags contains tag %}
|
||
|
<a href="{{ post.url }}" class="collection-item">
|
||
|
{{ post.title }}
|
||
|
</a>
|
||
|
{% endif %}
|
||
|
{% endfor %}
|
||
|
</div>
|
||
|
</div>
|
||
|
{% endfor %}
|