1
0
mirror of https://github.com/Unleash/unleash.git synced 2024-12-22 19:07:54 +01:00
unleash.unleash/websitev2/docusaurus.config.js

141 lines
4.8 KiB
JavaScript
Raw Normal View History

/** @type {import('@docusaurus/types').DocusaurusConfig} */
module.exports = {
title: "Unleash",
tagline: "The enterprise ready feature toggle service",
url: "https://docs.getunleash.io",
baseUrl: "/",
onBrokenLinks: "throw",
onBrokenMarkdownLinks: "warn",
favicon: "img/favicon.ico",
organizationName: "Unleash", // Usually your GitHub org/user name.
projectName: "unleash.github.io", // Usually your repo name.
themeConfig: {
defaultMode: 'light',
disableSwitch: true,
respectPrefersColorScheme: false,
2021-06-16 08:52:33 +02:00
algolia: {
apiKey: '9772249a7262b377ac876853d32bd760',
indexName: 'getunleash',
},
navbar: {
title: "Unleash",
logo: {
alt: "Unleash logo",
src: "img/logo.svg"
},
items: [
2021-06-05 00:25:35 +02:00
{ to: "/", label: "Documentation", activeBaseRegex: '(user_guide|sdks|addons|advanced)', },
{ to: "deploy/getting_started", label: "Deploy and manage" },
{ to: "integrations/integrations", label: "Integrations" },
{ to: "/api", label: "API" },
2021-06-04 19:31:28 +02:00
{ href: "https://www.getunleash.io/plans", label: "Unleash Enterprise", position: 'right' },
{
href: 'https://github.com/Unleash/unleash',
position: 'right',
className: 'header-github-link',
'aria-label': 'GitHub repository',
},
]
},
2021-06-04 14:50:52 +02:00
prism: {
2021-06-04 14:56:58 +02:00
additionalLanguages: ['java', 'swift', 'ruby', 'csharp', 'kotlin'],
2021-06-04 14:50:52 +02:00
},
footer: {
style: "dark",
links: [
{
title: "Docs",
items: [
{
label: "Docs",
to: "/"
}
]
},
{
title: "Community",
items: [
{
label: "Stack Overflow",
href: "https://stackoverflow.com/questions/tagged/unleash"
},
{
label: "Slack",
href: "https://join.slack.com/t/unleash-community/shared_invite/zt-8b6l1uut-LL67kLpIXm9bcN3~6RVaRQ"
},
{
label: "Twitter",
href: "https://twitter.com/getunleash"
}
]
},
{
title: "More",
items: [
{
label: "GitHub",
href: "https://github.com/Unleash/unleash"
}
]
}
],
copyright: `Copyright © ${new Date().getFullYear()} Unleash. Built with Docusaurus.`,
logo: {
src: 'img/logo.svg',
alt: 'Unleash logo'
}
},
gtag: {
trackingID: "UA-134882379-1"
},
image: 'img/logo.png'
},
presets: [
[
"@docusaurus/preset-classic",
{
docs: {
sidebarPath: require.resolve("./sidebars.js"),
// Please change this to your repo.
editUrl: "https://github.com/Unleash/unleash/edit/master/websitev2/",
routeBasePath: "/"
},
theme: {
customCss: require.resolve("./src/css/custom.css")
}
}
]
],
plugins: [
[
'@docusaurus/plugin-client-redirects',
{
fromExtensions: ['html', 'htm'],
redirects: [
{
2021-06-04 14:38:11 +02:00
to: '/sdks',
from: ['/user_guide/client-sdk', '/client-sdk']
},
2021-06-10 23:15:14 +02:00
{
to: '/user_guide/api-token',
from: '/deploy/user_guide/api-token'
},
{
to: '/sdks/unleash-proxy',
from: '/user_guide/native_apps/'
},
{
to: '/advanced/toggle_variants',
from: '/toggle_variants'
}
],
createRedirects: function (toPath) {
if (toPath.indexOf("/docs/") === -1 && toPath.indexOf("index.html") === -1) {
return `/docs/${toPath}`
}
}
}
]
]
};