Mirror of https://forge.levinkeller.de/levin/dorfarchiv.git
af129ed867f2e97da132cb3375de256c99af1b2b
148 lines · 4.1 KB
| 1 | import {themes as prismThemes} from 'prism-react-renderer'; |
| 2 | import type {Config} from '@docusaurus/types'; |
| 3 | import type * as Preset from '@docusaurus/preset-classic'; |
| 4 | |
| 5 | // This runs in Node.js - Don't use client-side code here (browser APIs, JSX...) |
| 6 | |
| 7 | const config: Config = { |
| 8 | title: 'My Site', |
| 9 | tagline: 'Dinosaurs are cool', |
| 10 | favicon: 'img/favicon.ico', |
| 11 | |
| 12 | // Future flags, see https://docusaurus.io/docs/api/docusaurus-config#future |
| 13 | future: { |
| 14 | v4: true, // Improve compatibility with the upcoming Docusaurus v4 |
| 15 | }, |
| 16 | |
| 17 | // Set the production url of your site here |
| 18 | url: 'https://your-docusaurus-site.example.com', |
| 19 | // Set the /<baseUrl>/ pathname under which your site is served |
| 20 | // For GitHub pages deployment, it is often '/<projectName>/' |
| 21 | baseUrl: '/', |
| 22 | |
| 23 | // GitHub pages deployment config. |
| 24 | // If you aren't using GitHub pages, you don't need these. |
| 25 | organizationName: 'facebook', // Usually your GitHub org/user name. |
| 26 | projectName: 'docusaurus', // Usually your repo name. |
| 27 | |
| 28 | onBrokenLinks: 'throw', |
| 29 | onBrokenMarkdownLinks: 'warn', |
| 30 | |
| 31 | // Even if you don't use internationalization, you can use this field to set |
| 32 | // useful metadata like html lang. For example, if your site is Chinese, you |
| 33 | // may want to replace "en" with "zh-Hans". |
| 34 | i18n: { |
| 35 | defaultLocale: 'en', |
| 36 | locales: ['en'], |
| 37 | }, |
| 38 | |
| 39 | presets: [ |
| 40 | [ |
| 41 | 'classic', |
| 42 | { |
| 43 | docs: { |
| 44 | sidebarPath: './sidebars.ts', |
| 45 | // Please change this to your repo. |
| 46 | // Remove this to remove the "edit this page" links. |
| 47 | editUrl: |
| 48 | 'https://github.com/facebook/docusaurus/tree/main/packages/create-docusaurus/templates/shared/', |
| 49 | }, |
| 50 | blog: { |
| 51 | showReadingTime: true, |
| 52 | feedOptions: { |
| 53 | type: ['rss', 'atom'], |
| 54 | xslt: true, |
| 55 | }, |
| 56 | // Please change this to your repo. |
| 57 | // Remove this to remove the "edit this page" links. |
| 58 | editUrl: |
| 59 | 'https://github.com/facebook/docusaurus/tree/main/packages/create-docusaurus/templates/shared/', |
| 60 | // Useful options to enforce blogging best practices |
| 61 | onInlineTags: 'warn', |
| 62 | onInlineAuthors: 'warn', |
| 63 | onUntruncatedBlogPosts: 'warn', |
| 64 | }, |
| 65 | theme: { |
| 66 | customCss: './src/css/custom.css', |
| 67 | }, |
| 68 | } satisfies Preset.Options, |
| 69 | ], |
| 70 | ], |
| 71 | |
| 72 | themeConfig: { |
| 73 | // Replace with your project's social card |
| 74 | image: 'img/docusaurus-social-card.jpg', |
| 75 | navbar: { |
| 76 | title: 'My Site', |
| 77 | logo: { |
| 78 | alt: 'My Site Logo', |
| 79 | src: 'img/logo.svg', |
| 80 | }, |
| 81 | items: [ |
| 82 | { |
| 83 | type: 'docSidebar', |
| 84 | sidebarId: 'tutorialSidebar', |
| 85 | position: 'left', |
| 86 | label: 'Tutorial', |
| 87 | }, |
| 88 | {to: '/blog', label: 'Blog', position: 'left'}, |
| 89 | { |
| 90 | href: 'https://github.com/facebook/docusaurus', |
| 91 | label: 'GitHub', |
| 92 | position: 'right', |
| 93 | }, |
| 94 | ], |
| 95 | }, |
| 96 | footer: { |
| 97 | style: 'dark', |
| 98 | links: [ |
| 99 | { |
| 100 | title: 'Docs', |
| 101 | items: [ |
| 102 | { |
| 103 | label: 'Tutorial', |
| 104 | to: '/docs/intro', |
| 105 | }, |
| 106 | ], |
| 107 | }, |
| 108 | { |
| 109 | title: 'Community', |
| 110 | items: [ |
| 111 | { |
| 112 | label: 'Stack Overflow', |
| 113 | href: 'https://stackoverflow.com/questions/tagged/docusaurus', |
| 114 | }, |
| 115 | { |
| 116 | label: 'Discord', |
| 117 | href: 'https://discordapp.com/invite/docusaurus', |
| 118 | }, |
| 119 | { |
| 120 | label: 'X', |
| 121 | href: 'https://x.com/docusaurus', |
| 122 | }, |
| 123 | ], |
| 124 | }, |
| 125 | { |
| 126 | title: 'More', |
| 127 | items: [ |
| 128 | { |
| 129 | label: 'Blog', |
| 130 | to: '/blog', |
| 131 | }, |
| 132 | { |
| 133 | label: 'GitHub', |
| 134 | href: 'https://github.com/facebook/docusaurus', |
| 135 | }, |
| 136 | ], |
| 137 | }, |
| 138 | ], |
| 139 | copyright: `Copyright © ${new Date().getFullYear()} My Project, Inc. Built with Docusaurus.`, |
| 140 | }, |
| 141 | prism: { |
| 142 | theme: prismThemes.github, |
| 143 | darkTheme: prismThemes.dracula, |
| 144 | }, |
| 145 | } satisfies Preset.ThemeConfig, |
| 146 | }; |
| 147 | |
| 148 | export default config; |