vercel / og-image

Open Graph Image as a Service - generate cards for Twitter, Facebook, Slack, etc
https://og-image.vercel.app
MIT License
4.05k stars 1.27k forks source link

Twitter image needs to be one word #237

Closed shinokada closed 1 year ago

shinokada commented 1 year ago

When I use it for twitter:image, title needs to be one word without a space.

This doesn't work with Twitter.

<meta name="twitter:image" content="https://open-graph-vercel.vercel.app/api/flowbite-svelte?title=Speed Dial">

This works.

<meta name="twitter:image" content="https://open-graph-vercel.vercel.app/api/flowbite-svelte?title=Speed-Dial">

image

What is the best way to use multiple words without hyphenes?

styfle commented 1 year ago

Try %20, like this:

<meta name="twitter:image" content="https://open-graph-vercel.vercel.app/api/flowbite-svelte?title=Speed%20Dial">

See the README for another example.

alexrabin commented 1 year ago

Adding the %20 helped me! Thank you!

Try %20, like this:

<meta name="twitter:image" content="https://open-graph-vercel.vercel.app/api/flowbite-svelte?title=Speed%20Dial">

See the README for another example.