feat: Add ability for different symbol per level#353
Open
thompson-tomo wants to merge 3 commits intothlorenz:masterfrom
Open
feat: Add ability for different symbol per level#353thompson-tomo wants to merge 3 commits intothlorenz:masterfrom
thompson-tomo wants to merge 3 commits intothlorenz:masterfrom
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds support for specifying different unordered list symbols per TOC nesting level via --entry-prefix, addressing #263’s request to align generated TOCs with a project’s existing markdownlint UL style.
Changes:
- Extend TOC generation to select a bullet symbol per header level from a comma-separated
--entry-prefixlist. - Add a transform test covering multi-level symbol cycling (
-,*,+). - Document the new per-level symbol configuration in the README.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 4 comments.
| File | Description |
|---|---|
lib/transform.js |
Splits entryPrefix into per-level symbols and selects a symbol based on nesting level. |
test/transform.js |
Adds coverage for per-level bullet symbols in generated TOC output. |
README.md |
Documents --entry-prefix for single and per-level list symbols and links it in the README TOC. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
48d9f15 to
1a3b82b
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Progresses #263
This enables the symbol used in unordered toc to differ on a per level basis.
This further assists with adoption as the tool can now work with whatever list symbol/s is used in the doc