diff --git a/src/components/BlogPostPreview.astro b/src/components/BlogPostPreview.astro new file mode 100644 index 0000000..85adbf8 --- /dev/null +++ b/src/components/BlogPostPreview.astro @@ -0,0 +1,9 @@ +--- +const { href, title, pubDate, desc } = Astro.props; +--- + +({pubDate}) {title}: "{desc}" diff --git a/src/pages/blog/index.astro b/src/pages/blog/index.astro index ee3aa86..920defe 100644 --- a/src/pages/blog/index.astro +++ b/src/pages/blog/index.astro @@ -1,30 +1,26 @@ --- import BaseLayout from "../../layouts/BaseLayout.astro"; +import BlogPostPreview from "../../components/BlogPostPreview.astro"; +const allPosts = Object.values( + import.meta.glob("./posts/*.md", { eager: true }), +); const pageTitle = "Blog"; --- - +

A blog may or may not help me in my life journey. I think it will help only because articulating my thoughts and ideas has brought me clarity, introspection, and reformation.

-
-

Duck Day 2026

-
-
- Demetrius Semanko -
- -
-
-

- When programming, we try to develop - something, but we also develop - problems. We try our best to fix the - problem, but we find ourselves struggling. Who or what can we turn to? -

- A duck! 🦆 -
- Read more... -
+ + {allPosts.map((post: any) => ( +
  • + +
  • + ))}
    diff --git a/src/pages/blog/post-1-duck-day-2026.md b/src/pages/blog/posts/post-1-duck-day-2026.md similarity index 98% rename from src/pages/blog/post-1-duck-day-2026.md rename to src/pages/blog/posts/post-1-duck-day-2026.md index 5f54c92..0328469 100644 --- a/src/pages/blog/post-1-duck-day-2026.md +++ b/src/pages/blog/posts/post-1-duck-day-2026.md @@ -1,5 +1,5 @@ --- -layout: ../../layouts/BlogPostLayout.astro +layout: ../../../layouts/BlogPostLayout.astro title: "Duck Day 2026" pubDate: 2026-03-03 description: "A detailing of WCUPAs Duck Day."