fix(docs): use blog post header image as OG image instead of default

Co-authored-by: himself65 <14026360+himself65@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot]
2026-03-01 06:54:23 +00:00
parent ea833a2be9
commit aa40a577e7
2 changed files with 17575 additions and 2 deletions

View File

@@ -272,8 +272,20 @@ export async function generateMetadata({
}
const page = blogs.getPage(slug);
if (!page) return notFound();
const { title, description } = page.data;
return { title, description };
const { title, description, image } = page.data;
return {
title,
description,
...(image && {
openGraph: {
images: [image],
},
twitter: {
card: "summary_large_image" as const,
images: [image],
},
}),
};
}
export function generateStaticParams() {

17561
landing/package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff