-
Notifications
You must be signed in to change notification settings - Fork 0
Closed
Labels
Description
Feature Request: Table of Contents (TOC) Generation
Description
Add functionality to automatically generate table of contents for markdown files based on their header structure.
Use Case
- Automatically generate TOCs for large documentation files
- Keep TOCs in sync when headers change during file operations
- Provide consistent navigation structure across documentation
Proposed Implementation
# Generate TOC for a single file
npx markmv toc document.md
# Generate TOC with custom depth
npx markmv toc document.md --depth 3
# Generate TOC with custom position
npx markmv toc document.md --position after-title
# Update existing TOC
npx markmv toc document.md --updateIntegration with Existing Features
- When splitting files, automatically generate TOCs for resulting files
- When joining files, merge TOCs or generate new comprehensive TOC
- When moving files, update TOC links automatically
Expected Output
- Insert TOC at specified position in markdown file
- Support for different TOC formats (numbered, bulleted, linked)
- Configurable depth levels and filtering options
- Automatic link generation to headers
Additional Context
This would complement the existing documentation organization features and provide better navigation for large markdown files.