Things are a changing

This commit is contained in:
Anton Pogrebnjak
2026-04-11 00:41:28 +02:00
parent 7e4f1acbf1
commit 31cae670c4
156 changed files with 97707 additions and 120 deletions
+32
View File
@@ -0,0 +1,32 @@
---
import BaseHead from '../../components/BaseHead.astro';
import Header from '../../components/Header.astro';
import Main from '../../components/Main.astro';
import Footer from '../../components/Footer.astro';
import { SITE_TITLE, SITE_DESCRIPTION } from '../../consts';
import { getCollection } from 'astro:content';
import Showcase from '../../components/Showcase.astro';
import { convertPost } from '../../models/Post';
const posts: Post[] = (await getCollection('blog')).map(convertPost).sort(
(a, b) => b.pubDate.valueOf() - a.pubDate.valueOf(),
);
---
<!doctype html>
<html lang="en">
<head>
<BaseHead title={SITE_TITLE} description={SITE_DESCRIPTION} />
</head>
<body>
<Header />
<Main>
{posts.length === 0 ? (
<h1 style="opacity: .5; user-select: none;">No posts yet &#128539;</h1>
) : (
<Showcase collection="blog" posts={posts} />
)}
</Main>
<Footer />
</body>
</html>