feat: add ogMetaImage support for blog posts and update metadata generation (#506)

- Introduced an optional `ogMetaImage` field in the blog configuration to enhance Open Graph image support.
- Updated the metadata generation logic to prioritize `ogMetaImage` over the default `ogImage`.
- Added a new Open Graph image for the 2026 roadmap blog post to improve social sharing visibility.
This commit is contained in:
Danny Avila
2026-02-18 22:12:10 -05:00
committed by GitHub
parent cf7ff45c05
commit 41f89c3ecc
4 changed files with 3 additions and 1 deletions

View File

@@ -88,7 +88,7 @@ export async function generateMetadata(props: PageProps): Promise<Metadata> {
const post = findPost(params.slug)
if (!post) notFound()
const ogImage = post.ogImage ?? '/images/socialcards/default-blog-image.png'
const ogImage = post.ogMetaImage ?? post.ogImage ?? '/images/socialcards/default-blog-image.png'
return {
title: post.title,

View File

@@ -7,6 +7,7 @@ tags:
- roadmap
- 2026
ogImage: /images/blog/2026-02-18_2026_roadmap.png
ogMetaImage: /images/blog/2026-02-18_2026_roadmap_og.png
ogImagePosition: center 10%
author: danny
---

Binary file not shown.

After

Width:  |  Height:  |  Size: 311 KiB

View File

@@ -14,6 +14,7 @@ export const blog = defineCollections({
date: z.string().or(z.date()),
author: z.string().optional(),
ogImage: z.string().optional(),
ogMetaImage: z.string().optional(),
ogImagePosition: z.string().optional(),
category: z.enum(['release', 'feature', 'guide', 'announcement']).optional(),
featured: z.boolean().optional(),