-
Notifications
You must be signed in to change notification settings - Fork 23
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
updated docs file structure fro api URL redirection
- Loading branch information
1 parent
01220a2
commit 469b7db
Showing
4 changed files
with
113 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -53,21 +53,34 @@ const config = { | |
sidebarPath: './sidebars.js', | ||
// Please change this to your repo. | ||
// Remove this to remove the "edit this page" links. | ||
editUrl: | ||
'https://github.com/coredao-org/CoreDAO-Docs/blob/main', | ||
|
||
path: 'docs', | ||
remarkPlugins: [remarkMath], | ||
rehypePlugins: [rehypeKatex], | ||
|
||
editUrl: 'https://github.com/coredao-org/CoreDAO-Docs/blob/main', | ||
routeBasePath: 'docs', | ||
path: 'docs', | ||
remarkPlugins: [remarkMath], | ||
rehypePlugins: [rehypeKatex], | ||
}, | ||
|
||
theme: { | ||
customCss: './src/css/custom.css', | ||
}, | ||
}, | ||
], | ||
], | ||
|
||
|
||
// plugins: [ | ||
// [ | ||
// '@docusaurus/plugin-content-docs', | ||
// { | ||
// id: 'api', | ||
// path: 'api', | ||
// routeBasePath: 'api', | ||
// sidebarPath: './sidebarsAPI.js', | ||
// // ... other options | ||
// }, | ||
// ], | ||
// ], | ||
|
||
stylesheets: [ | ||
{ | ||
href: 'https://cdn.jsdelivr.net/npm/[email protected]/dist/katex.min.css', | ||
|
@@ -102,36 +115,49 @@ const config = { | |
sidebarId: 'learnSidebar', | ||
position: 'left', | ||
label: 'Learn', | ||
activeBaseRegex: `/docs/`, | ||
}, | ||
{ | ||
type: 'docSidebar', | ||
sidebarId: 'devGuideSidebar', | ||
position: 'left', | ||
label: 'Developer Guide', | ||
activeBaseRegex: `/docs/`, | ||
}, | ||
{ | ||
type: 'docSidebar', | ||
sidebarId: 'nodeSidebar', | ||
position: 'left', | ||
label: 'Run a Node', | ||
activeBaseRegex: `/docs/`, | ||
}, | ||
{ | ||
type: 'docSidebar', | ||
sidebarId: 'stakeDelegateSidebar', | ||
position: 'left', | ||
label: 'Staking & Delegation', | ||
activeBaseRegex: `/docs/`, | ||
}, | ||
{ | ||
type: 'docSidebar', | ||
docId:'api', | ||
sidebarId: 'apiSidebar', | ||
position: 'left', | ||
label: 'Core API', | ||
activeBaseRegex: `/api/`, | ||
}, | ||
// { | ||
// to: '/api', // ./docs-api/Intro.md | ||
// label: 'Core API', | ||
// position: 'left', | ||
// activeBaseRegex: `/api/`, | ||
// }, | ||
{ | ||
type: 'docSidebar', | ||
sidebarId: 'faqSidebar', | ||
position: 'left', | ||
label: 'FAQs', | ||
activeBaseRegex: `/docs/`, | ||
}, | ||
|
||
{ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
/** | ||
* Creating a sidebar enables you to: | ||
- create an ordered group of docs | ||
- render a sidebar for each doc of that group | ||
- provide next/previous navigation | ||
The sidebars can be generated from the filesystem, or explicitly defined here. | ||
Create as many sidebars as you want. | ||
*/ | ||
|
||
// @ts-check | ||
|
||
/** @type {import('@docusaurus/plugin-content-docs').SidebarsConfig} */ | ||
const sidebars = { | ||
// By default, Docusaurus generates a sidebar from the docs folder structure | ||
|
||
apiSidebar:[ | ||
{ | ||
type: 'category', | ||
collapsed: true, | ||
label: '🔗 Connect with CORE API', | ||
link: {type: 'doc', id: 'api'}, | ||
items: [ | ||
{ | ||
type: 'category', | ||
collapsed: true, | ||
label: '📚 Tutorials', | ||
link: { | ||
type: 'generated-index', | ||
title: 'Core Scan Tutorials', | ||
description: 'Learn about how to use the Core Scan API', | ||
slug: '/api/category/core-api-tutorials', | ||
}, | ||
items: [ | ||
'tutorials/creating-an-account', | ||
'tutorials/generate-an-api-key', | ||
'tutorials/common-error-messages', | ||
] | ||
}, | ||
{ | ||
type: 'category', | ||
collapsed: true, | ||
label: '📑 API Documents', | ||
link: { | ||
type: 'generated-index', | ||
title: 'Core Scan API Documentation', | ||
description: 'Explore the various Core Scan API Endpoints', | ||
slug: '/api/category/core-api-docs', | ||
}, | ||
items: [ | ||
'api-documents/accounts', | ||
'api-documents/blocks', | ||
'api-documents/contracts', | ||
'api-documents/geth-proxy', | ||
'api-documents/statistics', | ||
'api-documents/transactions', | ||
] | ||
} | ||
] | ||
}, | ||
], | ||
|
||
}; | ||
|
||
export default sidebars; |