-
Notifications
You must be signed in to change notification settings - Fork 58
5 Sidebar Editing
Rakeden edited this page Jun 12, 2023
·
2 revisions
You may have found yourself adding a new page to the docs. Naturally it will be accessible through its generated URL.
However: You will want to include the new page inside the sidebar. Follow the next steps to learn how to modify the sidebar.
- Locate the configuration file of the VuePress site, in this case
/docs/.vuepress/config.js
- Open the configuration file in your preferred editor.
- Look for the
themeConfig
object within the file. - Within themeConfig, find the key
sidebar
, which defines the sidebar structure. - Modify the values in the sidebar or nav section to change the sidebar navigation. You can add, remove, or rearrange links as needed.
- Save the changes to the configuration file.
sidebar: [
{
title: 'Learn',
path: '/learn/',
collapsable: true,
sidebarDepth: 2,
initialOpenGroupIndex: 0,
children: [
{
title: 'About WAX',
path: '/learn/about-wax/',
collapsable: true,
sidebarDepth: 2,
children: [
{
title: 'What is WAX?',
path: '/learn/about-wax/what-is-wax',
},
],
},
],
},
];