index.md is landing pageindex.md represents the landing page for its directory.index is not part of URL pathnames.index.md maps to "" (empty string).index.md and no other files, the directory collapses to a leaf node (no collapsible in sidebar).Directory names wrapped in () act as groupers:
index.md(2. Category)Groupers are useful for visually grouping related pages without adding extra URL segments.
Example:
docs/
(Guides)/
setup.md
usage.md
Routes:
/setup/usageSidebar:
Guides ← grouper label (not a link)
Setup
Usage
Numeric prefixes on groupers only control ordering among other groupers — they never collide with indexes on regular files or directories. This is because the sort algorithm always places groupers after every regular file and directory at the same level, regardless of what prefix you give them.
Similarly, numeric prefixes on regular files and directories only control ordering among their own kind.
In short:
index.md is always sorted first.localeCompare.Example:
docs/
index.md
1. Getting Started.md
2. CLI Reference.md
(1. Guide)/
routing.md
(2. Configuration)/
smm-config.md
(3. Examples)/
structure.md
Sidebar order:
Home ← index.md first
Getting Started
CLI Reference
Guide ← grouper label (after all regular files)
Routing
Configuration ← next grouper
SMM Config
Examples ← last grouper
Structure
index.md and be clickable landing pagesExample:
docs/
guides/
index.md
setup.md
Routes:
/guides/guides/setupIf you use names like:
1. blahblah.md2. blhalbhablah.mdand set trimIndexFromPath: true in config, names can be ordered while emitted as clean paths.
The index prefix in filenames does not conflict with grouper indexes — they operate in separate sort tiers.
| Sidebar rendering | In URL path | Can have index.md |
|
|---|---|---|---|
| Regular directory | Collapsible | Yes | Yes |
Grouper (Name) |
Labeled section | No | No |
Route path segments are normalized by the CLI:
-.,;"'\\:<>?!` is removed(Group) are excluded from final pathname