firq-dev-website/src/pages/blog.astro

36 lines
902 B
Text
Raw Normal View History

2023-03-04 19:11:52 +01:00
---
2023-03-09 11:44:18 +01:00
import Layout from '../layouts/Layout.astro'
import BlogCard from '../components/blogCard.astro'
import BlogSection from '../layouts/blogSection.astro'
2023-03-04 19:11:52 +01:00
2023-03-09 11:44:18 +01:00
const description =
'My own small blog. Topics include FGO, TA, Programming, web technologies and more!'
2023-12-29 18:24:44 +01:00
const allPosts = await Astro.glob('../pages/blog/*.{md,mdx}')
2023-03-09 11:44:18 +01:00
allPosts.sort(
(a, b) =>
Date.parse(b.frontmatter.pubDate) - Date.parse(a.frontmatter.pubDate)
)
2023-03-04 19:11:52 +01:00
---
2023-03-09 11:44:18 +01:00
<Layout
title="Blog - Firq FGO Site"
currentpage="blog"
descriptionOverride={description}
>
<BlogSection title="Blog Articles">
{
allPosts.map((post) => (
<BlogCard
url={post.url}
title={post.frontmatter.title}
pubdate={post.frontmatter.pubDate}
description={post.frontmatter.description}
2023-03-19 13:14:50 +01:00
author={post.frontmatter.author}
2023-03-09 11:44:18 +01:00
/>
))
}
</BlogSection>
2023-03-04 19:11:52 +01:00
</Layout>
2023-03-09 11:44:18 +01:00
<style></style>