-
Notifications
You must be signed in to change notification settings - Fork 4.3k
/
Copy pathdocusaurus.config.js
204 lines (195 loc) · 5.87 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
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
// @ts-check
// Note: type annotations allow type checking and IDEs autocompletion
import "dotenv/config.js";
const yaml = require("js-yaml");
const fs = require("node:fs");
const path = require("node:path");
const { themes } = require("prism-react-renderer");
const lightCodeTheme = themes.github;
const darkCodeTheme = themes.dracula;
const docsHeaderDecoration = require("./src/remark/docsHeaderDecoration");
const enterpriseDocsHeaderInformation = require("./src/remark/enterpriseDocsHeaderInformation");
const productInformation = require("./src/remark/productInformation");
const connectorList = require("./src/remark/connectorList");
const specDecoration = require("./src/remark/specDecoration");
const docMetaTags = require("./src/remark/docMetaTags");
const redirects = yaml.load(
fs.readFileSync(path.join(__dirname, "redirects.yml"), "utf-8")
);
/** @type {import('@docusaurus/types').Config} */
const config = {
markdown: {
mermaid: true,
},
themes: ["@docusaurus/theme-mermaid"],
title: "Airbyte Documentation",
tagline:
"Airbyte is an open-source data integration platform to build ELT pipelines. Consolidate your data in your data warehouses, lakes and databases.",
url: "https://docs.airbyte.com/",
// Assumed relative path. If you are using airbytehq.github.io use /
// anything else should match the repo name
baseUrl: "/",
onBrokenLinks: "throw",
onBrokenMarkdownLinks: "throw",
favicon: "img/favicon.png",
organizationName: "airbytehq", // Usually your GitHub org/user name.
projectName: "airbyte", // Usually your repo name.
// Adds one off script tags to the head of each page
// e.g. <script async data-api-key="..." id="unifytag" src="..."></script>
scripts: [
{
src: "https://cdn.unifygtm.com/tag/v1/unify-tag-script.js",
async: true,
type: "module",
id: "unifytag",
"data-api-key": "wk_BEtrdAz2_2qgdexg5KRa6YWLWVwDdieFC7CAHkDKz",
},
{
src: "https://cdn.jsdelivr.net/npm/hockeystack@latest/hockeystack.min.js",
async: true,
"data-apikey": "2094e2379643f69f7aec647a15f786",
"data-cookieless": "1",
"data-auto-identify": "1",
},
],
headTags: [
{
tagName: "meta",
attributes: {
name: "zd-site-verification",
content: "plvcr4wcl9abmq0itvi63c",
},
},
],
plugins: [
[
"@docusaurus/plugin-client-redirects",
{
fromExtensions: ["html", "htm"], // /myPage.html -> /myPage
redirects: redirects,
},
],
() => ({
name: "Yaml loader",
configureWebpack() {
return {
module: {
rules: [
{
test: /\.ya?ml$/,
use: "yaml-loader",
},
{
test: /\.html$/i,
loader: "html-loader",
},
],
},
};
},
}),
],
customFields: {
requestErdApiUrl: process.env.REQUEST_ERD_API_URL,
},
clientModules: [
require.resolve("./src/scripts/cloudStatus.js"),
require.resolve("./src/scripts/download-abctl-buttons.js"),
require.resolve("./src/scripts/fontAwesomeIcons.js"),
],
presets: [
[
"classic",
/** @type {import('@docusaurus/preset-classic').Options} */
({
docs: {
routeBasePath: "/",
sidebarCollapsible: true,
sidebarPath: require.resolve("./sidebars.js"),
editUrl: "https://github.com/airbytehq/airbyte/blob/master/docs",
path: "../docs",
exclude: ["**/*.inapp.md"],
beforeDefaultRemarkPlugins: [specDecoration, connectorList], // use before-default plugins so TOC rendering picks up inserted headings
remarkPlugins: [
docsHeaderDecoration,
enterpriseDocsHeaderInformation,
productInformation,
docMetaTags,
],
},
blog: false,
theme: {
customCss: require.resolve("./src/css/custom.css"),
},
}),
],
],
themeConfig:
/** @type {import('@docusaurus/preset-classic').ThemeConfig} */
({
colorMode: {
disableSwitch: false,
},
docs: {
sidebar: {
autoCollapseCategories: true,
},
},
algolia: {
appId: "OYKDBC51MU",
apiKey: "15c487fd9f7722282efd8fcb76746fce", // Public API key: it is safe to commit it
indexName: "airbyte",
},
navbar: {
title: "",
logo: {
alt: "Simple, secure and extensible data integration",
src: "img/logo-dark.png",
srcDark: "img/logo-light.png",
height: 40,
},
items: [
{
href: "https://airbyte.io/",
position: "left",
label: "About Airbyte",
},
{
href: "https://airbyte.com/tutorials",
label: "Tutorials",
position: "left",
},
{
href: "https://support.airbyte.com/",
label: "Support",
position: "left",
},
// --- Right side ---
{
href: "https://status.airbyte.com",
label: "Cloud Status",
className: "cloudStatusLink",
position: "right",
},
{
href: "https://cloud.airbyte.io/signup?utm_campaign=22Q1_AirbyteCloudSignUpCampaign_Trial&utm_source=Docs&utm_content=NavBar",
label: "Try Airbyte Cloud",
position: "right",
className: "header-button",
},
{
href: "https://github.com/airbytehq",
position: "right",
"aria-label": "Airbyte on GitHub",
className: "header-github-link",
},
],
},
prism: {
theme: lightCodeTheme,
darkTheme: darkCodeTheme,
additionalLanguages: ["bash", "json"],
},
}),
};
module.exports = config;