mirror of
https://github.com/documenso/documenso.git
synced 2025-11-19 11:12:06 +10:00
feat: add og image to blog posts
This commit is contained in:
@ -17,7 +17,12 @@ export const generateMetadata = ({ params }: { params: { post: string } }) => {
|
|||||||
notFound();
|
notFound();
|
||||||
}
|
}
|
||||||
|
|
||||||
return { title: `Documenso - ${blogPost.title}` };
|
return {
|
||||||
|
title: `Documenso - ${blogPost.title}`,
|
||||||
|
openGraph: {
|
||||||
|
images: [`/api/blog-og?title=${blogPost.title}`],
|
||||||
|
},
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
const mdxComponents: MDXComponents = {
|
const mdxComponents: MDXComponents = {
|
||||||
|
|||||||
@ -145,7 +145,9 @@ export default async function handler(req: NextRequest) {
|
|||||||
/>
|
/>
|
||||||
</svg>
|
</svg>
|
||||||
|
|
||||||
<h1 tw="text-6xl mt-4 w-3/5 font-bold text-center">{title}</h1>
|
<h1 tw="text-6xl flex justify-center items-center mt-8 -mb-6 w-3/5 font-bold text-center mx-auto">
|
||||||
|
{title}
|
||||||
|
</h1>
|
||||||
</div>
|
</div>
|
||||||
),
|
),
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user