Configuration
SUMMARY.md
The SUMMARY.md file is the central configuration file for your book's navigation. Place it in the src/ directory and structure it as a nested list of links:
# Summary - [Introduction](intro.md) - [Chapter 1](ch01/index.md) - [Section 1.1](ch01/section1.md) - [Section 1.2](ch01/section2.md) - [Appendix](appendix.md)
Each - [Label](path) entry becomes a navigation link. Entries without links (like - Chapter 1) create collapsible group headings in the sidebar navigation.
Note:
Paths in SUMMARY.md are relative to the src/ directory. The compiler resolves them against the project's root directory.
Build Command
The standard build command is:
$ nim doc --project --outDir:docs --index:on --fullTextIndexation:on --summary:src/SUMMARY.md src/index.md
Key flags explained:
| Flag | Purpose |
|---|---|
| --project | Process all files recursively |
| --outDir:docs | Output directory |
| --index:on | Generate search index |
| --fullTextIndexation:on | Index all paragraphs, lists, and code for search |
| --summary:path | Use SUMMARY.md for navigation structure |
| --git.url:url | Base URL for source links |
| --git.commit:branch | Branch/commit for source links |