Skip to content

Commit 3236eb4

Browse files
committed
feat(docs): rename plugin and sidebars IDs
1 parent 9ec798b commit 3236eb4

File tree

3 files changed

+11
-11
lines changed

3 files changed

+11
-11
lines changed

docs/docusaurus.config.ts

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ const config: Config = {
6262
[
6363
"@docusaurus/plugin-content-docs",
6464
{
65-
id: "changelog",
65+
id: "changelogPlugin",
6666
path: "changelog",
6767
routeBasePath: "changelog",
6868
sidebarPath: "./sidebarsChangelog.ts",
@@ -82,31 +82,31 @@ const config: Config = {
8282
items: [
8383
{
8484
type: "docSidebar",
85-
sidebarId: "tutorialSidebar",
85+
sidebarId: "docsSidebar",
8686
position: "left",
8787
label: "Docs",
8888
},
8989
{
9090
label: "Changelog",
9191
position: "right",
9292
type: "docSidebar", // Remove this line when multiple changelog versions are needed
93-
sidebarId: "changelog1", // Remove this line when multiple changelog versions are needed
94-
docsPluginId: "changelog", // Remove this line when multiple changelog versions are needed
93+
sidebarId: "changelogSidebar1", // Remove this line when multiple changelog versions are needed
94+
docsPluginId: "changelogPlugin", // Remove this line when multiple changelog versions are needed
9595

9696
// Uncomment the following lines to enable dropdown multiple changelog versions
9797
// items: [
9898
// {
9999
// type: "docSidebar",
100-
// sidebarId: "changelog1",
101-
// docsPluginId: "changelog",
100+
// sidebarId: "changelogSidebar1",
101+
// docsPluginId: "changelogPlugin",
102102
// label: "v0.1.x",
103103
// },
104104
// Uncomment in sidebarsChangelog.ts changelog2 line to enable the second changelog version
105105
// add the next major version files in ./changelog/v0.2.x
106106
// {
107107
// type: "docSidebar",
108-
// sidebarId: "changelog2",
109-
// docsPluginId: "changelog",
108+
// sidebarId: "changelogSidebar2",
109+
// docsPluginId: "changelogPlugin",
110110
// label: "v0.2.x",
111111
// },
112112
// ],

docs/sidebars.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ import type { SidebarsConfig } from "@docusaurus/plugin-content-docs";
1414
*/
1515
const sidebars: SidebarsConfig = {
1616
// By default, Docusaurus generates a sidebar from the docs folder structure
17-
tutorialSidebar: [{ type: "autogenerated", dirName: "." }],
17+
docsSidebar: [{ type: "autogenerated", dirName: "." }],
1818

1919
// But you can create a sidebar manually
2020
/*

docs/sidebarsChangelog.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
import type { SidebarsConfig } from "@docusaurus/plugin-content-docs";
22

33
const sidebars: SidebarsConfig = {
4-
changelog1: [{ type: "autogenerated", dirName: "v0.1.x" }],
5-
// changelog2: [{ type: "autogenerated", dirName: "v0.2.x" }], // Uncomment this line to enable the second changelog version
4+
changelogSidebar1: [{ type: "autogenerated", dirName: "v0.1.x" }],
5+
// changelogSidebar2: [{ type: "autogenerated", dirName: "v0.2.x" }], // Uncomment this line to enable the second changelog version
66
};
77

88
export default sidebars;

0 commit comments

Comments
 (0)