forked from chidambaranadig/openapi-generator
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocusaurus.config.js
More file actions
executable file
·185 lines (163 loc) · 5.14 KB
/
docusaurus.config.js
File metadata and controls
executable file
·185 lines (163 loc) · 5.14 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
const fs = require('fs');
const path = require('path');
const parseYaml = require("js-yaml").safeLoad;
const loadYaml = relativePath => parseYaml(fs.readFileSync(path.join(__dirname, relativePath), "utf8"));
// See https://docusaurus.io/docs/site-config for all the possible
// site configuration options.
const team = loadYaml("src/dynamic/team.yml");
const users = loadYaml("src/dynamic/users.yml");
const sponsors = loadYaml("src/dynamic/sponsors.yml");
const baseUrl = '/';
const docusaurusConfig = {
title: 'OpenAPI Generator',
tagline: 'Generate clients, servers, and documentation from OpenAPI 2.0/3.x documents',
url: 'https://openapi-generator.tech', // Your website URL
baseUrl: baseUrl, // Base URL for your project */
favicon: 'img/favicon.png',
organizationName: 'OpenAPITools',
projectName: 'openapi-generator',
onBrokenLinks: 'ignore',
// // You may provide arbitrary config keys to be used as needed by your
// // template. For example, if you need your repo's URL...
// repoUrl: 'https://github.com/OpenAPITools/openapi-generator',
//plugins: ['@docusaurus/plugin-google-analytics'],
themeConfig: {
// Open Graph and Twitter card images.
image: 'img/docusaurus.png',
prism: {
theme: require('prism-react-renderer/themes/dracula'),
defaultLanguage: 'bash',
},
navbar: {
title: 'OpenAPI Generator',
logo: {
src: 'img/mono-logo.svg',
alt: 'OpenAPI Tools logo',
},
items: [
{to: 'docs/installation', label: 'Getting Started'},
{to: 'docs/generators', label: 'Generators'},
{to: 'docs/roadmap', label: 'Roadmap'},
{to: "docs/faq", label: "FAQ" },
{to: "team", label: "Team" },
{to: "blog", label: 'Blog'},
{to: 'https://api.openapi-generator.tech', label: 'API'},
],
},
algolia: {
appId: '51ITDG8FYN',
apiKey: '68eb9329427345f267486fd4f2d67b89',
indexName: 'openapi-generator',
},
footer: {
style: 'dark',
logo: {
alt: 'OpenAPI Tools',
src: 'img/mono-logo.svg',
href: 'https://openapi-generator.tech/',
},
copyright: `Copyright © ${new Date().getFullYear()} OpenAPI-Generator Contributors (https://openapi-generator.tech)`,
links: [
{
title: 'Docs',
items: [
{
label: 'Customizing Generators',
to: 'docs/customization',
},
{
label: 'Installation',
to: 'docs/installation',
},
{
label: 'Workflow Integrations',
to: 'docs/integrations',
},
],
},
{
title: 'Community',
items: [
{
label: 'User Showcase',
to: 'users',
},
{
label: 'Stack Overflow',
href: 'https://stackoverflow.com/questions/tagged/openapi-generator',
},
{
label: 'Chat Room',
href: 'https://join.slack.com/t/openapi-generator/shared_invite/zt-3ckklc3kl-gmWCnQlaTo5pfrTV8FCe_w',
},
{
label: 'Twitter',
href: 'https://twitter.com/oas_generator',
},
],
},
{
title: 'More',
items: [
{
label: 'Blog',
to: 'blog',
},
{
label: 'GitHub',
href: 'https://github.com/OpenAPITools/openapi-generator',
},
],
},
]
},
},
presets: [
[
'@docusaurus/preset-classic',
{
theme: {
customCss: require.resolve('./src/css/custom.css'),
},
docs: {
// docs folder path relative to website dir.
path: '../docs',
include: ['**/*.md', '**/*.mdx'],
// sidebars file relative to website dir.
sidebarPath: require.resolve('./sidebars.js'),
/**
* Theme components used by the docs pages
*/
docLayoutComponent: '@theme/DocPage',
docItemComponent: '@theme/DocItem',
sidebarCollapsible: true,
editUrl: 'https://github.com/OpenAPITools/openapi-generator/edit/master/website',
// Equivalent to `docsUrl`.
routeBasePath: 'docs',
// Remark and Rehype plugins passed to MDX. Replaces `markdownOptions` and `markdownPlugins`.
remarkPlugins: [],
rehypePlugins: [],
// Equivalent to `enableUpdateBy`.
showLastUpdateAuthor: true,
// Equivalent to `enableUpdateTime`.
showLastUpdateTime: true,
},
googleAnalytics: {
trackingID: 'UA-132927057-1',
},
},
],
],
// Add custom scripts here that would be placed in <script> tags.
scripts: [
'https://buttons.github.io/buttons.js',
'https://cdnjs.cloudflare.com/ajax/libs/clipboard.js/2.0.0/clipboard.min.js',
`${baseUrl}js/code-block-buttons.js`,
],
customFields: {
users: users,
sponsors: sponsors,
team: team
},
};
module.exports = docusaurusConfig;