Auto Navigation
Your sidebar is generated automatically from your file structure.
GetPagemark walks your repository recursively and builds a hierarchical navigation tree. No configuration file needed — just organize your files and folders.
How Files Map to Nav Items
- Top-level
.mdfiles become top-level nav links. - Folders become collapsible sections with a chevron toggle.
index.mdinside a folder sets the section's title and metadata.- Other files inside a folder become child nav links.
Controlling Order
By default, items are sorted alphabetically by title. Use the order frontmatter field to override:
--- title: Introduction order: 1 ---
Lower numbers sort first. Items without an order value default to 999.
Section Titles
Folder names are converted to title case by default (getting-started → "Getting Started"). Override this by adding an index.md with a title frontmatter field.
Folder Behavior
Clicking a folder section toggles it open/closed. Folders don't navigate — they just expand to reveal their children. The active page is highlighted and its parent sections are automatically expanded.
Mobile
On screens narrower than 768px, the sidebar collapses into a hamburger menu. A toggle button appears in the header to open/close it as an overlay.