-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocusaurus.config.js
More file actions
225 lines (205 loc) · 6.11 KB
/
docusaurus.config.js
File metadata and controls
225 lines (205 loc) · 6.11 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
// @ts-check
// `@type` JSDoc annotations allow editor autocompletion and type checking
// (when paired with `@ts-check`).
// There are various equivalent ways to declare your Docusaurus config.
// See: https://docusaurus.io/docs/api/docusaurus-config
import {
duotoneDark,
github,
gruvboxMaterialDark,
jettwaveDark,
nightOwl,
themes as prismThemes,
} from 'prism-react-renderer';
// This runs in Node.js - Don't use client-side code here (browser APIs, JSX...)
/** @type {import('@docusaurus/types').Config} */
const config = {
title: 'PHP Unitary',
tagline: 'For developers who like their data structured and their coffee strong',
// GitHub Pages project sites should use root-level favicon + baseUrl-aware paths
favicon: 'favicon.ico',
// Set the production url of your site here
url: 'https://maplephp.github.io',
// Set the /<baseUrl>/ pathname under which your site is served
baseUrl: '/unitary/',
organizationName: 'MaplePHP',
projectName: 'Unitary',
deploymentBranch: 'gh-pages',
trailingSlash: false,
onBrokenLinks: 'throw',
onBrokenMarkdownLinks: 'warn',
i18n: {
defaultLocale: 'en',
locales: ['en'],
},
presets: [
[
'classic',
/** @type {import('@docusaurus/preset-classic').Options} */
({
docs: {
sidebarPath: './sidebars.js',
},
blog: {
showReadingTime: true,
feedOptions: {
type: ['rss', 'atom'],
xslt: true,
},
onInlineTags: 'warn',
onInlineAuthors: 'warn',
onUntruncatedBlogPosts: 'warn',
},
theme: {
customCss: './src/css/custom.css',
},
gtag: {
trackingID: 'G-M3092KZDQF',
anonymizeIP: true,
},
}),
],
],
// Add link tags for icons/manifest (baseUrl-aware for GitHub Pages project sites)
headTags: [
{
tagName: 'meta',
attributes: {
name: 'algolia-site-verification',
content: 'E26F10C563888C99',
},
},
{
tagName: 'link',
attributes: {
rel: 'apple-touch-icon',
sizes: '180x180',
href: '/unitary/apple-touch-icon.png',
},
},
{
tagName: 'link',
attributes: {
rel: 'icon',
type: 'image/png',
sizes: '96x96',
href: '/unitary/favicon-96x96.png',
},
},
{
tagName: 'link',
attributes: {
rel: 'manifest',
href: '/unitary/site.webmanifest',
},
},
// Optional: Safari pinned tab icon
// {
// tagName: 'link',
// attributes: {
// rel: 'mask-icon',
// href: '/unitary/safari-pinned-tab.svg',
// color: '#5bbad5',
// },
// },
],
themeConfig:
/** @type {import('@docusaurus/preset-classic').ThemeConfig} */
({
algolia: {
appId: '3SHRGH4EEU',
apiKey: '76329c646b57a7751fa2f6f536521bf2', // "Search-Only API Key" (safe to expose)
indexName: 'unitary',
// Recommended:
contextualSearch: true,
searchParameters: {},
// Optional but useful:
insights: true, // enable click analytics if you also enable it in Algolia
},
colorMode: {
defaultMode: 'dark',
disableSwitch: true,
respectPrefersColorScheme: false,
},
// Social card is fine in img/ (this is not an auto-discovery path)
image: 'img/validate-social-card.png',
// Meta tags go here (NOT link tags)
metadata: [
{name: 'theme-color', content: '#ffffff'},
{name: 'msapplication-TileColor', content: '#ffffff'},
],
navbar: {
title: 'PHP Unitary',
logo: {
alt: 'Unitary',
src: 'img/logo.svg',
},
items: [
{
type: 'docSidebar',
sidebarId: 'tutorialSidebar',
position: 'left',
label: 'The Documentation',
},
{to: '/validation-api', label: 'Validation API', position: 'left'},
{to: '/why-unitary', label: 'Why Unitary?', position: 'left'},
{to: '/faq', label: 'FAQ', position: 'left'},
{
type: 'search',
position: 'right',
},
{
href: 'https://github.com/maplephp/unitary',
label: 'GitHub',
position: 'right',
},
],
},
footer: {
style: 'light',
links: [
{
title: 'Docs',
items: [
{label: 'Get started', to: '/docs/get-started'},
{label: 'Write Tests', to: '/docs/run-tests'},
{label: 'Run Tests', to: '/docs/run-tests'},
],
},
{
title: 'Community',
items: [
{label: 'GitHub', href: 'https://github.com/maplephp/unitary'},
{label: 'LinkedIn', href: 'https://se.linkedin.com/in/daniel-ronkainen-161b3386/en'},
],
},
{
title: 'More',
items: [
{label: 'Unitary', href: 'https://github.com/maplephp/unitary'},
{label: 'Emitron', href: 'https://github.com/maplephp/maplephp'},
{label: 'HTTP message', href: 'https://github.com/maplephp/http'},
{label: 'Prompts', href: 'https://github.com/maplephp/Prompts'},
{label: 'Blunder', href: 'https://github.com/maplephp/Blunder'},
],
},
{
title: 'More',
items: [
{label: 'Validate', href: 'https://github.com/maplephp/validate'},
{label: 'Darn Tidy object', href: 'https://github.com/maplephp/dto'},
{label: 'Container', href: 'https://github.com/maplephp/container'},
{label: 'Cache', href: 'https://github.com/maplephp/cache'},
],
},
],
copyright: `Copyright © ${new Date().getFullYear()} Darn Tidy Object (Unitary), Inc. Built with Docusaurus.`,
},
prism: {
additionalLanguages: ['php'],
theme: prismThemes.github,
darkTheme: prismThemes.jettwaveDark,
},
}),
};
export default config;