diff --git a/public/assets/og-preview-image.webp b/public/assets/og-preview-image.webp new file mode 100644 index 0000000000..a9184c5c46 Binary files /dev/null and b/public/assets/og-preview-image.webp differ diff --git a/vite.config.ts b/vite.config.ts index cd4980c58b..ddaa1f76da 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -60,6 +60,25 @@ const previewAnalyticsTag = { }, } +const previewMetaTag = [ + { + injectTo: 'head' as const, + tag: 'meta', + attrs: { + property: 'og:image', + content: '/assets/og-preview-image.webp', + }, + }, + { + injectTo: 'head' as const, + tag: 'meta', + attrs: { + property: 'og:description', + content: 'Preview of the Oxide web console with in-browser mock API', + }, + }, +] + // see https://vitejs.dev/config/ export default defineConfig(({ mode }) => ({ build: { @@ -85,7 +104,7 @@ export default defineConfig(({ mode }) => ({ plugins: [ createHtmlPlugin({ inject: { - tags: process.env.VERCEL ? [previewAnalyticsTag] : [], + tags: process.env.VERCEL ? [previewAnalyticsTag, ...previewMetaTag] : [], }, }), react(),