|
| 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: 'Laravel 한국어 문서', |
| 9 | + tagline: 'PHP 웹 애플리케이션 프레임워크', |
| 10 | + favicon: 'img/favicon.ico', |
| 11 | + |
| 12 | + // Set the production url of your site here |
| 13 | + url: 'https://letsescape.github.io', |
| 14 | + // Set the /<baseUrl>/ pathname under which your site is served |
| 15 | + // For GitHub pages deployment, it is often '/<projectName>/' |
| 16 | + baseUrl: '/laravel-docs-web/', |
| 17 | + |
| 18 | + // GitHub pages deployment config. |
| 19 | + // If you aren't using GitHub pages, you don't need these. |
| 20 | + organizationName: 'letsescape', // Usually your GitHub org/user name. |
| 21 | + projectName: 'laravel-docs-web', // Usually your repo name. |
| 22 | + |
| 23 | + onBrokenLinks: 'warn', |
| 24 | + onBrokenMarkdownLinks: 'warn', |
| 25 | + |
| 26 | + // Even if you don't use internationalization, you can use this field to set |
| 27 | + // useful metadata like html lang. For example, if your site is Chinese, you |
| 28 | + // may want to replace "en" with "zh-Hans". |
| 29 | + i18n: { |
| 30 | + defaultLocale: 'ko', |
| 31 | + locales: ['ko', 'en'], |
| 32 | + }, |
| 33 | + |
| 34 | + themes: [ |
| 35 | + [ |
| 36 | + require.resolve("@easyops-cn/docusaurus-search-local"), |
| 37 | + { |
| 38 | + hashed: true, |
| 39 | + language: ["en", "ko"], |
| 40 | + highlightSearchTermsOnTargetPage: true, |
| 41 | + explicitSearchResultPath: true, |
| 42 | + }, |
| 43 | + ], |
| 44 | + ], |
| 45 | + |
| 46 | + plugins: [ |
| 47 | + [ |
| 48 | + '@docusaurus/plugin-content-docs', |
| 49 | + { |
| 50 | + id: 'default', |
| 51 | + path: 'docs', |
| 52 | + routeBasePath: 'docs', |
| 53 | + sidebarPath: './sidebars.ts', |
| 54 | + // 버전 관리 설정 |
| 55 | + includeCurrentVersion: true, |
| 56 | + lastVersion: 'current', |
| 57 | + versions: { |
| 58 | + current: { |
| 59 | + label: '12.x', |
| 60 | + path: '', |
| 61 | + }, |
| 62 | + '11.x': { |
| 63 | + label: '11.x', |
| 64 | + path: '11.x', |
| 65 | + }, |
| 66 | + }, |
| 67 | + // 기타 설정 |
| 68 | + editUrl: 'https://github.com/letsescape/laravel-docs-web/tree/main/', |
| 69 | + }, |
| 70 | + ], |
| 71 | + ], |
| 72 | + |
| 73 | + presets: [ |
| 74 | + [ |
| 75 | + 'classic', |
| 76 | + { |
| 77 | + docs: false, // 플러그인으로 대체 |
| 78 | + blog: false, |
| 79 | + theme: { |
| 80 | + customCss: './src/css/custom.css', |
| 81 | + }, |
| 82 | + } satisfies Preset.Options, |
| 83 | + ], |
| 84 | + ], |
| 85 | + |
| 86 | + themeConfig: { |
| 87 | + // Replace with your project's social card |
| 88 | + image: 'img/laravel-social-card.jpg', |
| 89 | + |
| 90 | + navbar: { |
| 91 | + title: 'Laravel 한국어 문서', |
| 92 | + logo: { |
| 93 | + alt: 'Laravel Logo', |
| 94 | + src: 'img/logo.svg', |
| 95 | + }, |
| 96 | + items: [ |
| 97 | + { |
| 98 | + type: 'docSidebar', |
| 99 | + sidebarId: 'tutorialSidebar', |
| 100 | + position: 'left', |
| 101 | + label: '문서', |
| 102 | + }, |
| 103 | + { |
| 104 | + type: 'docsVersionDropdown', |
| 105 | + position: 'right', |
| 106 | + dropdownItemsAfter: [], |
| 107 | + dropdownActiveClassDisabled: true, |
| 108 | + }, |
| 109 | + { |
| 110 | + type: 'localeDropdown', |
| 111 | + position: 'right', |
| 112 | + }, |
| 113 | + { |
| 114 | + href: 'https://github.com/letsescape/laravel-docs-web', |
| 115 | + label: 'GitHub', |
| 116 | + position: 'right', |
| 117 | + }, |
| 118 | + ], |
| 119 | + }, |
| 120 | + footer: { |
| 121 | + style: 'dark', |
| 122 | + links: [ |
| 123 | + { |
| 124 | + title: '문서', |
| 125 | + items: [ |
| 126 | + { |
| 127 | + label: '시작하기', |
| 128 | + to: '/docs/intro', |
| 129 | + }, |
| 130 | + { |
| 131 | + label: '아키텍처 개념', |
| 132 | + to: '/docs/architecture/container', |
| 133 | + }, |
| 134 | + ], |
| 135 | + }, |
| 136 | + { |
| 137 | + title: '커뮤니티', |
| 138 | + items: [ |
| 139 | + { |
| 140 | + label: 'Laravel Korea', |
| 141 | + href: 'https://laravel.kr', |
| 142 | + }, |
| 143 | + ], |
| 144 | + }, |
| 145 | + { |
| 146 | + title: '더 보기', |
| 147 | + items: [ |
| 148 | + { |
| 149 | + label: 'GitHub', |
| 150 | + href: 'https://github.com/letsescape/laravel-docs-web', |
| 151 | + }, |
| 152 | + ], |
| 153 | + }, |
| 154 | + ], |
| 155 | + copyright: `Copyright © ${new Date().getFullYear()} Laravel 한국어 문서. Built with Docusaurus.`, |
| 156 | + }, |
| 157 | + prism: { |
| 158 | + theme: prismThemes.github, |
| 159 | + darkTheme: prismThemes.dracula, |
| 160 | + }, |
| 161 | + } satisfies Preset.ThemeConfig, |
| 162 | +}; |
| 163 | + |
| 164 | +export default config; |
0 commit comments