gopxl logo

Directory structure

For docgen to properly organize and render your documentation, you should follow the following directory and file structure:

  • docs/ (documentation root)
    • 01. First Section/ (directory)
      • 01. First Page.md
      • 02. Second Page.md
    • 02. Second Section/ (directory)
      • 01. First Page.md
      • 02. Second Page.md

At the root level of your documentation directory, each directory represents a section of your documentation. Inside each section directory, you can place Markdown files corresponding to individual pages.

[!NOTE] Markdown files that are not placed directly within a section directory will not appear in the navigation menu, though they can still be linked from other pages.

Ordering

The order of sections and pages within the menu is determined by the filesystem's alphabetical ordering. To control this order, each directory and file should be prefixed with a number (e.g. 01.). These numerical prefixes are automatically stripped out during the rendering process, so they do not appear in the menu or URLs.


Edit this page on Github