main
  1import { defineConfig } from 'vitepress'
  2
  3// https://vitepress.dev/reference/site-config
  4export default defineConfig({
  5  base: '/zx/',
  6  outDir: 'build',
  7  cleanUrls: true,
  8  title: 'google/zx',
  9  titleTemplate: ':title | google/zx',
 10  description: 'A tool for writing better scripts',
 11  head: [
 12    [
 13      'link',
 14      {
 15        rel: 'apple-touch-icon',
 16        sizes: '180x180',
 17        href: '/zx/img/favicons/apple-touch-icon.png',
 18      },
 19    ],
 20    [
 21      'link',
 22      {
 23        rel: 'icon',
 24        type: 'image/png',
 25        sizes: '32x32',
 26        href: '/zx/img/favicons/favicon-32x32.png',
 27      },
 28    ],
 29    [
 30      'link',
 31      {
 32        rel: 'icon',
 33        type: 'image/png',
 34        sizes: '16x16',
 35        href: '/zx/img/favicons/favicon-16x16.png',
 36      },
 37    ],
 38    [
 39      'link',
 40      {
 41        rel: 'mask-icon',
 42        href: '/zx/img/favicons/safari-pinned-tab.svg',
 43        color: '#3a0839',
 44      },
 45    ],
 46    ['link', { rel: 'shortcut icon', href: '/zx/img/favicons/favicon.ico' }],
 47    ['meta', { name: 'og:image', content: '/zx/img/og-image.png' }],
 48    ['meta', { name: 'twitter:image', content: '/zx/img/og-image.png' }],
 49  ],
 50  themeConfig: {
 51    logo: '/img/logo.svg',
 52    // https://vitepress.dev/reference/default-theme-config
 53    nav: [
 54      { text: 'Home', link: '/' },
 55      { text: 'Docs', link: '/getting-started' },
 56    ],
 57
 58    sidebar: {
 59      '/': [
 60        {
 61          text: 'Docs',
 62          items: [
 63            { text: 'Getting Started', link: '/getting-started' },
 64            { text: 'Setup', link: '/setup' },
 65            { text: 'API Reference', link: '/api' },
 66            { text: 'CLI Usage', link: '/cli' },
 67            { text: 'Configuration', link: '/configuration' },
 68            { text: 'Process Promise', link: '/process-promise' },
 69            { text: 'Process Output', link: '/process-output' },
 70            { text: 'Contribution Guide', link: '/contribution' },
 71            { text: 'Architecture', link: '/architecture' },
 72            { text: 'Migration from v7', link: '/migration-from-v7' },
 73            { text: '⚡ zx@lite', link: '/lite' },
 74          ],
 75        },
 76        {
 77          text: 'FAQ',
 78          link: '/faq',
 79          items: [
 80            { text: 'Quotes', link: '/quotes' },
 81            { text: 'Shell', link: '/shell' },
 82            { text: 'TypeScript', link: '/typescript' },
 83            { text: 'Markdown Scripts', link: '/markdown' },
 84            { text: 'Known Issues', link: '/known-issues' },
 85          ],
 86        },
 87      ],
 88    },
 89
 90    socialLinks: [{ icon: 'github', link: 'https://github.com/google/zx' }],
 91
 92    editLink: {
 93      pattern: 'https://github.com/google/zx/blob/main/docs/:path',
 94    },
 95
 96    footer: {
 97      message:
 98        'Disclaimer: This is not an officially supported Google product.',
 99    },
100
101    search: {
102      provider: 'local',
103    },
104  },
105})