1
0
mirror of https://github.com/Unleash/unleash.git synced 2024-10-18 20:09:08 +02:00
unleash.unleash/website/docusaurus.config.js
Fredrik Strand Oseberg acb98db00f
docs: add docs for impression data (#1328)
* docs: add docs for impression data

* fix: update wording

* Update website/docs/advanced/impression_data.md

Co-authored-by: Thomas Heartman <thomas@getunleash.ai>

* Update website/docs/advanced/impression_data.md

Co-authored-by: Thomas Heartman <thomas@getunleash.ai>

* docs: use hyphen instead of underscore in file name and title/slug

We've been very inconsistent with our use of separators previously
(we should try and find a standard). Hyphens are most common online,
so I've switched to that instead.

* docs: use syntax highlighting for shell commands

* docs: start outlining impression data restructure.

* docs: Add impression data info to API: create toggles

* docs: Add impression data row to compatibility matrix

* docs: restructures the impression data reference doc.

* chore: remove question callout in source material

* docs: add redirect for `impression_data` -> 'impression-data'

* docs: Add sdk availability to availability note

* chore: Fix broken doc paths.

Co-authored-by: Thomas Heartman <thomas@getunleash.ai>
2022-02-08 12:11:08 +01:00

180 lines
6.0 KiB
JavaScript

/** @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.
trailingSlash: false,
themeConfig: {
defaultMode: 'light',
disableSwitch: true,
respectPrefersColorScheme: false,
algolia: {
apiKey: '9772249a7262b377ac876853d32bd760',
indexName: 'getunleash',
},
navbar: {
title: 'Unleash',
logo: {
alt: 'Unleash logo',
src: 'img/logo.svg',
},
items: [
{
to: '/',
label: 'Documentation',
activeBaseRegex: '(user_guide|sdks|addons|advanced)',
},
{
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': 'Unleash GitHub repository',
},
],
},
prism: {
additionalLanguages: [
'java',
'swift',
'ruby',
'csharp',
'kotlin',
'php',
],
},
footer: {
style: 'dark',
links: [
{
title: 'Product',
items: [
{
label: 'Docs',
to: '/',
},
{
label: 'Unleash on GitHub',
href: 'https://github.com/Unleash/unleash',
},
{
label: 'Roadmap',
href: 'https://github.com/orgs/Unleash/projects/5',
},
],
},
{
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',
},
],
},
],
copyright: `Copyright © ${new Date().getFullYear()} Unleash. Built with Docusaurus.`,
logo: {
src: 'img/logo.svg',
alt: 'Unleash logo',
},
},
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/main/website/',
routeBasePath: '/',
remarkPlugins: [
[
require('@docusaurus/remark-plugin-npm2yarn'),
{ sync: true },
],
],
},
theme: {
customCss: require.resolve('./src/css/custom.css'),
},
googleAnalytics: {
trackingID: 'UA-134882379-1',
},
},
],
],
plugins: [
[
'@docusaurus/plugin-client-redirects',
{
fromExtensions: ['html', 'htm'],
redirects: [
{
to: '/sdks',
from: [
'/user_guide/client-sdk',
'/client-sdk',
'/user_guide/connect_sdk',
'/sdks/community',
],
},
{
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',
},
{
to: '/integrations',
from: '/integrations/integrations',
},
{
to: '/user_guide/activation_strategy',
from: '/user_guide/control_rollout',
},
{
from: '/advanced/impression_data',
to: '/advanced/impression-data',
}
],
createRedirects: function (toPath) {
if (
toPath.indexOf('/docs/') === -1 &&
toPath.indexOf('index.html') === -1
) {
return `/docs/${toPath}`;
}
},
},
],
],
};