Skip to content

Commit 3ea6045

Browse files
authored
fix: use absolute url for og:image tag (#270)
* fix: use absolute url for og:image tag * fix: open graph tags are under property instead of name * refactor: use vercel env to read site url * fix: try again with hardcoded url
1 parent 9e794f8 commit 3ea6045

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

app/routes/__root.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ export const Route = createRootRouteWithContext<{
4040
...seo({
4141
title: 'TanStack | High Quality Open-Source Software for Web Developers',
4242
description: `Headless, type-safe, powerful utilities for complex workflows like Data Management, Data Visualization, Charts, Tables, and UI Components.`,
43-
image: ogImage,
43+
image: `https://tanstack.com${ogImage}`,
4444
keywords:
4545
'tanstack,react,reactjs,react query,react table,open source,open source software,oss,software',
4646
}),

app/utils/seo.ts

+4-4
Original file line numberDiff line numberDiff line change
@@ -17,14 +17,14 @@ export const seo = ({
1717
{ name: 'twitter:description', content: description },
1818
{ name: 'twitter:creator', content: '@tannerlinsley' },
1919
{ name: 'twitter:site', content: '@tannerlinsley' },
20-
{ name: 'og:type', content: 'website' },
21-
{ name: 'og:title', content: title },
22-
{ name: 'og:description', content: description },
20+
{ property: 'og:type', content: 'website' },
21+
{ property: 'og:title', content: title },
22+
{ property: 'og:description', content: description },
2323
...(image
2424
? [
2525
{ name: 'twitter:image', content: image },
2626
{ name: 'twitter:card', content: 'summary_large_image' },
27-
{ name: 'og:image', content: image },
27+
{ property: 'og:image', content: image },
2828
]
2929
: []),
3030
]

0 commit comments

Comments
 (0)