diff --git a/apps/app/app/app.vue b/apps/app/app/app.vue index 5b71240..64cb7e2 100644 --- a/apps/app/app/app.vue +++ b/apps/app/app/app.vue @@ -16,12 +16,8 @@ useSeoMeta({ ogType: 'website', ogSiteName: 'shhh', ogUrl: () => url.href, - // Absolute, not `/og-image.png`: every unfurler resolves it against nothing and needs the origin. - ogImage: () => `${url.origin}/og-image.png`, - ogImageWidth: 1200, - ogImageHeight: 630, - twitterCard: 'summary_large_image', - twitterImage: () => `${url.origin}/og-image.png`, + // No card image here: `pages/index.vue` adds one for the home page alone, so a shared paste link unfurls small instead of eating the conversation it lands in. + twitterCard: 'summary', twitterTitle: t('seo.title'), twitterDescription: t('seo.description') }) diff --git a/apps/app/app/pages/index.vue b/apps/app/app/pages/index.vue index f53ad0f..8033101 100644 --- a/apps/app/app/pages/index.vue +++ b/apps/app/app/pages/index.vue @@ -3,6 +3,17 @@ import type { TabsItem } from '@nuxt/ui' const { t } = useI18n() const localePath = useLocalePath() +const url = useRequestURL() + +// The large preview card is the home page's alone — every other route, a paste above all, keeps the compact one set in `app.vue`. +useSeoMeta({ + // Absolute, not `/og-image.png`: every unfurler resolves it against nothing and needs the origin. + ogImage: () => `${url.origin}/og-image.png`, + ogImageWidth: 1200, + ogImageHeight: 630, + twitterCard: 'summary_large_image', + twitterImage: () => `${url.origin}/og-image.png` +}) await ensureAuthSessionLoaded() const user = useAuthUser()