feat: Add dynamic Open Graph image generation with correct aspect ratio

- Create /api/og-image endpoint that generates SVG with 1.91:1 ratio (1200x630px)
- Prevents logo cropping on Facebook and Twitter
- Uses safe padding (150px) to ensure content is never cut off
- Update default OG image to use dynamic endpoint
- Add SEO testing documentation
This commit is contained in:
Hördle Bot
2025-12-01 19:44:48 +01:00
parent 9006b208af
commit a8867ac42e
3 changed files with 314 additions and 1 deletions

View File

@@ -14,7 +14,7 @@ export const config = {
linkUrl: process.env.NEXT_PUBLIC_CREDITS_LINK_URL || 'https://digitalcourage.social/@elpatron',
},
seo: {
ogImage: process.env.NEXT_PUBLIC_OG_IMAGE || '/favicon.ico',
ogImage: process.env.NEXT_PUBLIC_OG_IMAGE || '/api/og-image',
twitterHandle: process.env.NEXT_PUBLIC_TWITTER_HANDLE || undefined,
}
};