Add function that looks for all blogs

This commit is contained in:
Quinn Hegeman
2026-03-08 15:12:19 +01:00
parent 4d56dce1af
commit 3317926f61
8 changed files with 143 additions and 1 deletions

6
astro/src/lib/dates.ts Normal file
View File

@@ -0,0 +1,6 @@
export function formatDate(date: Date, format: string) {
return format
.replaceAll("%Y", date.getFullYear().toString())
.replaceAll("%M", (date.getMonth() + 1).toString().padStart(2, '0'))
.replaceAll("%D", date.getDate().toString().padStart(2, '0'));
}