I have a SUMMARY.md
file for rendering the Docsify sidebar:
* [SW-Module](module/README.md)
* [AGB](module/agb.md)
* [Style guide](module/styles.md)
* [Start](module/start.md)
And my Docsify configuration is done like this in index.html
:
window.$docsify = {
alias: {
'/.*/SUMMARY.md': 'SUMMARY.md'
},
name: 'Name',
repo: 'https://github.com/org/repo',
loadSidebar: 'SUMMARY.md',
basePath: "./",
maxLevel: 2,
subMaxLevel: 1,
auto2top: false
}
And the result right now looks like this:
What I want is to have the subtitles AGB, Style Guide and Start collapsed, in order to only see SW-Module and expand them when clicking on SW-Module.
I tried a lot of different configs, but I couldn't achieve this behaviour yet.
Any help would be greatly appreciated.
you can edit the file '_sidebar.md' with just the first level of your headers, then use the next config -> { loadSidebar: true, }
in this way, you are gonna have in your left sidebar just the first level but the library is gonna grasp the rest of the hierarchy on the fly. You can expand and collapse each header.