mirror of
https://github.com/noodlapp/noodl-docs.git
synced 2026-01-11 06:42:55 +01:00
feat: Add GitHub Pages workflow (#50)
* feat: Add GitHub Pages workflow * chore: Switch to GitHub pages
This commit is contained in:
@@ -1,39 +1,17 @@
|
||||
// @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');
|
||||
|
||||
const {
|
||||
_parseNoodlMarkupPlugin,
|
||||
_parseRenderedMarkupPlugin,
|
||||
} = require('./plugins/markdown-syntax');
|
||||
|
||||
const version = require('./package.json')
|
||||
.version.split('.')
|
||||
.slice(0, 2)
|
||||
.join('.');
|
||||
|
||||
// Reverse the sidebar items ordering (including nested category items)
|
||||
function reverseSidebarItems(items) {
|
||||
// Reverse items in categories
|
||||
const result = items.map((item) => {
|
||||
if (item.type === 'category') {
|
||||
return { ...item, items: reverseSidebarItems(item.items) };
|
||||
}
|
||||
return item;
|
||||
});
|
||||
// Reverse items at current level
|
||||
result.reverse();
|
||||
return result;
|
||||
}
|
||||
|
||||
/** @type {import('@docusaurus/types').Config} */
|
||||
const config = {
|
||||
title: 'Noodl',
|
||||
tagline: 'Dinosaurs are cool',
|
||||
url: 'https://docs.noodl.net',
|
||||
baseUrl: `/${version}/`,
|
||||
url: 'https://noodlapp.github.io',
|
||||
baseUrl: `/noodl-docs/`,
|
||||
onBrokenLinks: 'throw',
|
||||
onBrokenMarkdownLinks: 'warn',
|
||||
favicon: 'img/favicon.ico',
|
||||
|
||||
Reference in New Issue
Block a user