import {themes as prismThemes} from 'prism-react-renderer'; import type {Config} from '@docusaurus/types'; import type * as Preset from '@docusaurus/preset-classic'; const config: Config = { title: '雑記 by swallow', tagline: '技術・思考・作ったもの', favicon: 'img/favicon.ico', future: { v4: true, }, url: 'https://docs.techswan.online', baseUrl: '/', onBrokenLinks: 'warn', onBrokenMarkdownLinks: 'warn', i18n: { defaultLocale: 'ja', locales: ['ja'], }, plugins: [ // Tech(技術記事)用のドキュメント [ '@docusaurus/plugin-content-docs', { id: 'tech', path: 'docs-tech', routeBasePath: 'tech', sidebarPath: './sidebars-tech.ts', }, ], ], presets: [ [ 'classic', { docs: { path: 'docs', routeBasePath: '/blog', sidebarPath: './sidebars.ts', }, blog: false, theme: { customCss: './src/css/custom.css', }, } satisfies Preset.Options, ], ], themeConfig: { colorMode: { defaultMode: 'dark', respectPrefersColorScheme: true, }, navbar: { title: '雑記 by swallow', items: [ { to: '/blog', label: 'Blog', position: 'left', }, { to: '/tech', label: 'Tech', position: 'left', }, { to: '/works', label: 'Works', position: 'left', }, ], }, footer: { style: 'dark', copyright: `© ${new Date().getFullYear()} swallow`, }, prism: { theme: prismThemes.github, darkTheme: prismThemes.dracula, additionalLanguages: ['bash', 'json', 'yaml', 'python'], }, tableOfContents: { minHeadingLevel: 2, maxHeadingLevel: 4, }, } satisfies Preset.ThemeConfig, }; export default config;