feat: created basic blog layout

This commit is contained in:
Leyla Becker 2026-02-10 11:02:43 -06:00
parent 42fd071301
commit 0d41db36ef
13 changed files with 935 additions and 3 deletions

27
tags.njk Normal file
View file

@ -0,0 +1,27 @@
---
pagination:
data: collections.postsByTag
size: 1
alias: tag
addAllPagesToCollections: true
permalink: /tags/{{ tag }}/
layout: base.njk
---
<h1>Posts tagged "#{{ collections.postsByTag[tag].name }}"</h1>
<ul class="post-list">
{% for post in collections.postsByTag[tag].posts %}
<li>
<a href="{{ post.url }}" class="post-card">
<h2>{{ post.data.title }}</h2>
<time datetime="{{ post.date | dateFormat }}">{{ post.date | dateFormat }}</time>
{% if post.data.description %}
<p>{{ post.data.description }}</p>
{% endif %}
</a>
</li>
{% endfor %}
</ul>
<p><a href="/tags/"><3E> All tags</a></p>