<meta property="og:image:height" content="630" />
contentType
opengraph-image.tsx / twitter-image.tsx export const contentType = 'image/png'
 
export default function Image() {}
<head> output <meta property="og:image:type" content="image/png" />
Route Segment Config
opengraph-image and twitter-image are specialized Route Handlers that can use the same route segment configuration options as Pages and Layouts.
OptionTypeDefaultdynamic'auto' | 'force-dynamic' | 'error' | 'force-static''auto'revalidatefalse | 'force-cache' | 0 | numberfalseruntime'nodejs' | 'edge''nodejs'preferredRegion'auto' | 'global' | 'home' | string | string[]'auto'
app/opengraph-image.tsx export const runtime = 'edge'
 
export default function Image() {}
Examples
Using external data