feat: 🎉 initial commit
This commit is contained in:
commit
b3003321c9
35 changed files with 9015 additions and 0 deletions
45
src/posts.njk
Normal file
45
src/posts.njk
Normal file
|
@ -0,0 +1,45 @@
|
|||
---
|
||||
layout: postlist.njk
|
||||
title: Posts
|
||||
eleventyNavigation:
|
||||
key: posts
|
||||
order: 3
|
||||
pagination:
|
||||
data: collections.posts
|
||||
size: 10
|
||||
alias: blogposts
|
||||
---
|
||||
|
||||
{% for post in blogposts | reverse %}
|
||||
<article class="blogpost">
|
||||
<h1>{{ post.data.title }}</h1>
|
||||
<aside class="not-prose space-y-4 text-base">
|
||||
<ul class="postmeta">
|
||||
<li>
|
||||
{% lucide "calendar", {"size": "20"} %}
|
||||
<time datetime="{{ post.date | isoDate }}" title="{{ post.date | longDate }}">
|
||||
{{ post.date | readableDate }}
|
||||
</time>
|
||||
</li>
|
||||
<li>
|
||||
{% lucide "user", {"size": "20"} %}
|
||||
<a href="{{ post.data.author.href }}">{{ post.data.author.name }}</a>
|
||||
</li>
|
||||
<li>
|
||||
{% lucide "glasses", {"size": "20"} %}
|
||||
{{ post.content | readingtime }}
|
||||
</li>
|
||||
</ul>
|
||||
</aside>
|
||||
|
||||
{% if post.data.image and post.data.image.src != '' %}
|
||||
<img src="{{ post.data.image.src }}" alt="{{ post.data.image.alt }}">
|
||||
{% endif %}
|
||||
|
||||
<p>{{ post.data.description }}</p>
|
||||
|
||||
<a href="{{ post.url }}" class="not-prose read-more-button">
|
||||
Read on {% lucide "chevron-right", {"size":"20"} %}
|
||||
</a>
|
||||
</article>
|
||||
{% endfor %}
|
Loading…
Add table
Add a link
Reference in a new issue