gitdocs
gitdocs copied to clipboard
Add TOC max-depth custom config support & styling
Issue: Current implementation would render maximum header depth of 2 inside the TOC without an ability to customise that. Headers with level > 2 were not being rendered nor linkable inside the TOC.
Fix:
- Added support for passing custom
max_depthconfiguration in.gitdocs.jsonto allow overriding the default value. - Added styling of nested headers inside the TOC
After:

Before (having headers in the .md file from h1 to h5, it displays only level 1 & 2 without any visual indications of their level ):

@zsherman hey there, not sure if anyone still maintains this, anyway I opened this small PR a small improvement, would be glad if you can have a look, tnx :)
Hi @rontalx we appreciate the PR! We're not actively using Gitdocs but are happy to take a look, it looks like there's a linting error in CI but once that's fixed up I'd be happy to merge.