-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocusaurus.config.js
117 lines (112 loc) · 3.31 KB
/
docusaurus.config.js
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
const config = require('../lib/config/docusaurus');
const codeComponentTagger = require('./lib/plugins/content-tags/remark/tagger').default;
const displayJSON = require('./lib/plugins/display-json/remark/plugin').default;
const highlight = require('./lib/plugins/highlight/remark/plugin').default;
const merge = require('./lib/utils/merge').default;
const pluginPath = (name) => `./lib/plugins/${name}/index.js`;
const defaultConfig = {
// title: '', // website title
themes: [pluginPath('engine-module'), pluginPath('content-tags'), pluginPath('display-json'), pluginPath('open-api'), pluginPath('highlight')], // themes (client side code)
staticDirectories: ['../static'],
// tagline: '', // website tagline
// url: '', // website url
baseUrl: '/',
trailingSlash: false,
// organizationName: '', // github organization name
// projectName: '', // github repo name
deploymentBranch: 'gh-pages',
// scripts: [] // scripts to be added to every page in the website
stylesheets: [
'https://fonts.googleapis.com/css?family=Lato%3A400%2C400i%2C700%2C900&ver=4.5.3',
'https://fonts.googleapis.com/css?family=Montserrat%3A400%2C500%2C600%2C700%2C900&ver=4.5.3',
],
onBrokenLinks: 'throw',
onBrokenMarkdownLinks: 'throw',
plugins: [ // plugins (server side code)
'docusaurus-plugin-sass',
'docusaurus-plugin-clarity',
[
'@docusaurus/plugin-client-redirects',
{
redirects: {},
},
],
[
'docusaurus-gtm-plugin',
{
id: '', // google gtm id
},
],
],
presets: [
[
'@docusaurus/preset-classic',
{
docs: {
remarkPlugins: [codeComponentTagger, displayJSON, highlight],
showLastUpdateAuthor: true,
showLastUpdateTime: true,
// editUrl: '', // url for suggesting edits
path: '../pages',
routeBasePath: '/',
// sidebarPath: '', // path to sidebar items
// sidebarItemsGenerator: '', // custom sidebar item generator
sidebarCollapsible: true,
sidebarCollapsed: true,
},
blog: {},
theme: {
// customCss: [], // global css stylesheets
},
pages: {
path: '../src/pages'
}
},
],
],
themeConfig: {
docs: {
sidebar: {
autoCollapseCategories: true,
},
},
metadata: [
// {
// name: 'google-site-verification',
// content: '', // google site verification data
// },
],
clarity: {
// ID: '', // clarity id
},
colorMode: {
defaultMode: 'dark',
disableSwitch: false,
respectPrefersColorScheme: false,
},
navbar: {
style: 'dark',
// title: '', // navbar title
// logo: {
// alt: '',
// src: '',
// srcDark: '',
// }, // navbar logo
// items: [], // navbar items
},
// image: '', // default embed image
prism: {
additionalLanguages: ['powershell', 'yaml'],
},
algolia: {
// apiKey: '', // algolia api key
// indexName: '', // algolia index name
// appId: '', // algolia app id
contextualSearch: true,
algoliaOptions: {},
},
},
};
const finalizeConfig = async(d, t) => merge(d, await t)
const fullConfig = finalizeConfig(defaultConfig, config);
module.exports = fullConfig;