Skip to content

Commit

Permalink
Merge pull request #272 from d-rec/add-mermaid-to-docs-plugin
Browse files Browse the repository at this point in the history
Add Mermaid using plugin
  • Loading branch information
dmohns authored May 30, 2024
2 parents 6208bce + 8045169 commit 4bd6574
Show file tree
Hide file tree
Showing 3 changed files with 3,337 additions and 958 deletions.
75 changes: 39 additions & 36 deletions docs/.vitepress/config.mjs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { defineConfig } from 'vitepress';
import { generateSidebar } from 'vitepress-sidebar';
import { withMermaid } from 'vitepress-plugin-mermaid';

// https://vitepress-sidebar.jooy2.com/getting-started
const vitepressSidebarOptions = {
Expand All @@ -12,41 +13,43 @@ const vitepressSidebarOptions = {
};

// https://vitepress.dev/reference/site-config
export default defineConfig({
title: 'D-REC Docs',
description:
'Documentation for the D-REC (Distributed Renewable Energy Certificates) platform',

head: [['link', { rel: 'icon', type: 'image/png', href: 'favicon.png' }]],

// For hosting on Github pages
// https://vitepress.dev/guide/deploy#github-pages
base: '/drec-origin/',
vite: {
publicDir: '.public',
},
srcExclude: ['README.md'],

themeConfig: {
// https://vitepress.dev/reference/default-theme-config
logo: '/D-REC-banner.png',
nav: [
{ text: 'Home', link: '/' },
{ text: 'Documentation', link: '/introduction/technology-overview' },
],
footer: {
message: 'Built with VitePress ❤️.',
copyright: `Copyright © ${new Date().getFullYear()} D-REC Initiative.`,
export default withMermaid(
defineConfig({
title: 'D-REC Docs',
description:
'Documentation for the D-REC (Distributed Renewable Energy Certificates) platform',

head: [['link', { rel: 'icon', type: 'image/png', href: 'favicon.png' }]],

// For hosting on Github pages
// https://vitepress.dev/guide/deploy#github-pages
base: '/drec-origin/',
vite: {
publicDir: '.public',
},

sidebar: generateSidebar(vitepressSidebarOptions),

socialLinks: [
{ icon: 'github', link: 'https://github.com/d-rec/drec-origin' },
],

search: {
provider: 'local',
srcExclude: ['README.md'],

themeConfig: {
// https://vitepress.dev/reference/default-theme-config
logo: '/D-REC-banner.png',
nav: [
{ text: 'Home', link: '/' },
{ text: 'Documentation', link: '/introduction/technology-overview' },
],
footer: {
message: 'Built with VitePress ❤️.',
copyright: `Copyright © ${new Date().getFullYear()} D-REC Initiative.`,
},

sidebar: generateSidebar(vitepressSidebarOptions),

socialLinks: [
{ icon: 'github', link: 'https://github.com/d-rec/drec-origin' },
],

search: {
provider: 'local',
},
},
},
});
}),
);
Loading

0 comments on commit 4bd6574

Please sign in to comment.