feat: enhance blog detail page with engagement features including likes and comments

This commit is contained in:
poyrazavsever
2026-03-10 21:11:13 +03:00
parent d262b391c9
commit 5d83541761
4 changed files with 438 additions and 122 deletions
+3 -1
View File
@@ -1,6 +1,7 @@
import { notFound } from "next/navigation";
import { BlogDetailContent } from "@/components/blog-detail-content";
import { getBlogDetailBySlug } from "@/data/blog-detail";
import { getBlogEngagementBySlug } from "@/data/blog-engagement";
type BlogDetailPageProps = {
params: Promise<{ slug: string }>;
@@ -9,10 +10,11 @@ type BlogDetailPageProps = {
export default async function BlogDetailPage({ params }: BlogDetailPageProps) {
const { slug } = await params;
const post = getBlogDetailBySlug(slug);
const engagement = getBlogEngagementBySlug(slug);
if (!post) {
notFound();
}
return <BlogDetailContent post={post} />;
return <BlogDetailContent post={post} engagement={engagement} />;
}