Files
Jiachi LiuandGitHub 7af9c43911 Fix metadata nested twitter props rendering (#47972)
For twitter and og image nested properties we should render them as
snake case according to [og spec](https://ogp.me/) and [twitter card
docs](https://developer.twitter.com/en/docs/twitter-for-websites/cards/guides/getting-started).
For typing we keep them as camel case and then convert them to snake
case during render

This issue is reported in #47960 that user thinks the types are
incorrect, but turns out twitter metadata didn't render it correctly

Closes #47960
2023-04-05 22:15:10 +00:00

20 lines
388 B
TypeScript

export default function page() {
return 'twitter summary'
}
export const metadata = {
twitter: {
title: 'Twitter Title',
description: 'Twitter Description',
siteId: 'siteId',
creator: 'creator',
creatorId: 'creatorId',
images: [
{
url: 'https://twitter.com/image.png',
secureUrl: 'https://twitter.com/secure.png',
},
],
},
}