Update welcome post content and formatting; implement dynamic blog owner name in layout and post metadata; add author field to post structure and API routes.
This commit is contained in:
@@ -18,6 +18,7 @@ export interface Post {
|
||||
summary: string;
|
||||
content: string;
|
||||
createdAt: Date;
|
||||
author: string;
|
||||
}
|
||||
|
||||
const postsDirectory = path.join(process.cwd(), 'posts');
|
||||
@@ -50,6 +51,7 @@ export async function getPostBySlug(slug: string): Promise<Post> {
|
||||
summary: data.summary,
|
||||
content: processedContent.toString(),
|
||||
createdAt,
|
||||
author: process.env.NEXT_PUBLIC_BLOG_OWNER || 'Anonymous',
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user