Skip to content

Commit

Permalink
docs: add og meta
Browse files Browse the repository at this point in the history
  • Loading branch information
skryukov committed Jun 17, 2024
1 parent 120e4b4 commit b7b37d6
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 2 deletions.
21 changes: 19 additions & 2 deletions docs/.vitepress/config.mts
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,15 @@ import {defineConfig} from 'vitepress'
import {tabsMarkdownPlugin} from 'vitepress-plugin-tabs'


const title = 'Inertia Rails'
const description = 'Community documentation for Inertia.js Rails adapter'
const site = 'https://inertia-rails.netlify.app'
const image = `${site}/og_image.jpg`

// https://vitepress.dev/reference/site-config
export default defineConfig({
title: "Inertia Rails",
description: "Community documentation for Inertia.js Rails adapter",
title,
description,

markdown: {
config(md) {
Expand All @@ -16,6 +21,18 @@ export default defineConfig({
head: [
['link', {rel: 'icon', href: '/favicon.ico', sizes: "32x32"}],
['link', {rel: 'icon', href: '/icon.svg', type: 'image/svg+xml'}],

['meta', { name: 'twitter:card', content: 'summary_large_image' }],
['meta', { name: 'twitter:site', content: site }],
['meta', { name: 'twitter:description', value: description }],
['meta', { name: 'twitter:image', content: image }],

['meta', { property: 'og:type', content: 'website' }],
['meta', { property: 'og:locale', content: 'en_US' }],
['meta', { property: 'og:site', content: site }],
['meta', { property: 'og:site_name', content: title }],
['meta', { property: 'og:image', content: image }],
['meta', { property: 'og:description', content: description }],
],

themeConfig: {
Expand Down
Binary file added docs/public/og_image.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit b7b37d6

Please sign in to comment.