Open source Loom alternative. Beautiful, shareable screen recordings.
Rust appcapcossloommacnextjsnextjs15open-sourceossreactrecordrustscreen-capturescreen-recorderscreenshotsolidjstauritauri-apptypescriptvite
feat(web): support updatedAt in blog post metadata
Richie McIlroy127f91d0c011
diff --git a/apps/web/utils/blog.ts b/apps/web/utils/blog.tsindex 800c17cc9..6c25bb99a 100644--- a/apps/web/utils/blog.ts+++ b/apps/web/utils/blog.ts@@ -6,6 +6,7 @@ export type PostMetadata = {title: string;author: string;publishedAt: string;+ updatedAt?: string;summary: string;description: string;tags?: string;@@ -32,10 +33,11 @@ interface InteractiveBlogPost {title: string;description: string;publishedAt: string;+ updatedAt?: string;author: string;tags?: string[];image?: string;- [key: string]: any;+ [key: string]: unknown;}function parseFrontmatter(fileContent: string) {@@ -120,7 +122,8 @@ function getMDXData(dir: string): BlogPost[] {function getInteractiveBlogPosts(): BlogPost[] {try {- const interactivePosts = getAllInteractiveBlogPosts();+ const interactivePosts: InteractiveBlogPost[] =+ getAllInteractiveBlogPosts();return interactivePosts.map((post) => ({slug: post.slug,@@ -128,9 +131,11 @@ function getInteractiveBlogPosts(): BlogPost[] {title: post.title,author: post.author,publishedAt: post.publishedAt,+ updatedAt: post.updatedAt,summary: post.description,description: post.description,tags: post.tags?.join(", ") || "",+ image: post.image ?? "/og.png",},content: "",isManual: true,