From 184ff9351dd2ff58b97fb46ab18fc3e717d4677d Mon Sep 17 00:00:00 2001
From: Ryan Wang
Date: Tue, 7 Apr 2026 23:26:08 +0800
Subject: [PATCH] Extract post list into reusable fragment
Add public/fragments/post-list.html containing the shared post list markup, and update src/pages/category.astro and src/pages/index.astro to replace the in-file duplicate list with . This removes duplicated template code and centralizes the post list for easier maintenance; existing empty-feed and pagination logic remain unchanged.
---
public/fragments/post-list.html | 19 +++++++++++++++++++
src/pages/category.astro | 22 ++--------------------
src/pages/index.astro | 22 ++--------------------
3 files changed, 23 insertions(+), 40 deletions(-)
create mode 100644 public/fragments/post-list.html
diff --git a/public/fragments/post-list.html b/public/fragments/post-list.html
new file mode 100644
index 0000000..5947964
--- /dev/null
+++ b/public/fragments/post-list.html
@@ -0,0 +1,19 @@
+