Include descriptions on blog article list

This commit is contained in:
thiloho
2025-04-29 04:13:12 +02:00
parent 036d806313
commit 25c95db4c1
2 changed files with 16 additions and 14 deletions

View File

@@ -1,7 +1,8 @@
--- ---
title: "Custom email domain" title: "Custom email domain"
description: "Find out how having your own email domain can save you a lot of time when switching email providers." description: "Find out how having your own domain can save you a lot of time when switching email providers."
pubDate: "2025-04-28" pubDate: "2025-04-28"
modDate: "2025-04-29"
--- ---
## Introduction ## Introduction

View File

@@ -13,17 +13,18 @@ const sortedArticles = allArticles.sort((a, b) => {
title="Blog" title="Blog"
description="Friendly technical articles with a focus on web and GNU/Linux topics." description="Friendly technical articles with a focus on web and GNU/Linux topics."
> >
<ul>
{ {
sortedArticles.map(({ id, data: { title, pubDate } }) => ( sortedArticles.map(({ id, data: { title, pubDate, description } }) => (
<li> <article class="mt-8 flex flex-col gap-2 first:mt-0">
<Date date={pubDate} /> <Date date={pubDate} />
<span>&raquo;</span> <a
<a class="text-blue-800 hover:no-underline" href={`/blog/${id}`}> class="max-w-fit text-blue-800 hover:no-underline"
href={`/blog/${id}`}
>
{title} {title}
</a> </a>
</li> <p class="not-prose">{description}</p>
</article>
)) ))
} }
</ul>
</PageLayout> </PageLayout>