Files
discordeno/website/docusaurus.config.js
Peter 285908b306 Feat: Website Rewrite (#2996)
* Feat: Remake website

* update yarn.lock

---------

Co-authored-by: Peter Hanania <peter@pogy.xyz>
Co-authored-by: Skillz4Killz <23035000+Skillz4Killz@users.noreply.github.com>
2023-04-15 21:11:44 +00:00

158 lines
4.3 KiB
JavaScript

// @ts-check
// Note: type annotations allow type checking and IDEs autocompletion
const lightCodeTheme = require('prism-react-renderer/themes/github')
const darkCodeTheme = require('prism-react-renderer/themes/dracula')
/** @type {import('@docusaurus/types').Config} */
const config = {
title: 'Discordeno',
tagline: 'Making Scalable Bots Easy!',
favicon: 'img/favicon.png',
// Set the production url of your site here
url: 'https://discordeno.js.org/',
// Set the /<baseUrl>/ pathname under which your site is served
// For GitHub pages deployment, it is often '/<projectName>/'
baseUrl: '/',
// GitHub pages deployment config.
// If you aren't using GitHub pages, you don't need these.
organizationName: 'discordeno', // Usually your GitHub org/user name.
projectName: 'discordeno', // Usually your repo name.
deploymentBranch: 'gh-pages',
trailingSlash: false,
onBrokenLinks: 'throw',
onBrokenMarkdownLinks: 'warn',
// Even if you don't use internalization, you can use this field to set useful
// metadata like html lang. For example, if your site is Chinese, you may want
// to replace "en" with "zh-Hans".
i18n: {
defaultLocale: 'en',
locales: ['en'],
},
presets: [
[
'classic',
/** @type {import('@docusaurus/preset-classic').Options} */
({
docs: {
sidebarPath: require.resolve('./sidebars.js'),
// Please change this to your repo.
// Remove this to remove the "edit this page" links.
editUrl:
'https://github.com/facebook/docusaurus/tree/main/packages/create-docusaurus/templates/shared/',
},
blog: {
showReadingTime: true,
// Please change this to your repo.
// Remove this to remove the "edit this page" links.
editUrl:
'https://github.com/facebook/docusaurus/tree/main/packages/create-docusaurus/templates/shared/',
},
theme: {
customCss: require.resolve('./src/styling/index.css'),
},
}),
],
],
themeConfig:
/** @type {import('@docusaurus/preset-classic').ThemeConfig} */
({
// Replace with your project's social card
image: 'img/links-embed-image.png',
navbar: {
title: 'Discordeno',
logo: {
alt: 'Discordeno Logo',
src: 'img/logo.svg',
},
items: [
{
type: 'doc',
docId: 'intro',
position: 'left',
label: 'Tutorial',
},
{ to: '/blog', label: 'Blog', position: 'left' },
{
href: 'https://discord.gg/ddeno',
label: 'Discord',
position: 'right',
},
{
href: 'https://github.com/discordeno/discordeno',
label: 'GitHub',
position: 'right',
},
],
},
footer: {
style: 'light',
links: [
{
title: 'Docs',
items: [
{
label: 'Tutorial',
to: '/docs/intro',
},
],
},
{
title: 'Community',
items: [
{
label: 'Discord',
href: 'https://discord.gg/ddeno',
},
],
},
{
title: 'More',
items: [
{
label: 'Blog',
to: '/blog',
},
{
label: 'GitHub',
href: 'https://github.com/discordeno/discordeno',
},
],
},
],
copyright: `Copyright © ${new Date().getFullYear()} 2021-2023, Discordeno.`,
},
prism: {
theme: lightCodeTheme,
darkTheme: darkCodeTheme,
},
}),
plugins: [
[
require.resolve('@easyops-cn/docusaurus-search-local'),
{
indexDocs: true,
indexPages: true,
docsRouteBasePath: ['/docs', '/tutorial'],
language: ['en'],
hashed: true,
docsDir: ['docs', 'tutorial'],
blogDir: [],
removeDefaultStopWordFilter: true,
highlightSearchTermsOnTargetPage: true,
searchResultLimits: 8,
searchResultContextMaxLength: 50,
},
],
],
}
module.exports = config