I'm trying to represent my folder tree in the sidebar but when I click on one of the Group
parent elements, the children elements are not rendered.
Another thing that's weird is that the Group
elements have no cursor: pointer
css property, like you would expect on a clickable object. This is my .vitepress/config.ts
export default {
title: "blub docs",
description: "blub",
themeConfig: {
nav: [
{ text: 'Home', link: '/' },
{ text: 'Examples', link: '/markdown-examples' }
],
sidebar: {
'/': [
{
text: 'Group 1',
collapsible: true,
children: [
'/group1/page1.md',
'/group1/page2.md',
],
},
{
text: 'Group 2',
collapsible: true,
children: [
'/group2/page1.md',
'/group2/page2.md',
],
},
],
}
}
}
I've also commented out the layout
from root/index.md
so that the sidebar is visible on the landing page (if that is relevant):
[//]: # (layout: home)
This is the default layout of vitepress. I've implemented a custom layout but ended up having exactly the same issue.