fix: remove redundant TOC picker from legacy HTML template.#808
Conversation
Removed the `__TOC_PICKER__` placeholder from the template and its corresponding generation logic in `replaceTemplateValues.mjs` to prevent duplicate Table of Contents rendering.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
PR SummaryMedium Risk Overview Updates the legacy HTML template and Reviewed by Cursor Bugbot for commit edff75f. Bugbot is set up for automated code reviews on this repo. Configure here. |
avivkeller
left a comment
There was a problem hiding this comment.
This affects every page of an already legacy UI, why?
- Added a new CLI flag: --index-redirect-url. - Added redirect handling for generated index.html pages. - Added a smart JavaScript redirect with a meta refresh fallback - Replaced the hardcoded / header link with a configurable __HOME_LINK__ template value
Sorry, I misunderstood the scope of the issue initially. You're right that the original approach was too broad since it affected all pages in the legacy UI. I've reworked the implementation so the behavior is now opt-in via a new |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 0206b3b. Configure here.


Removed the
__TOC_PICKER__placeholder from the template and its corresponding generation logic inreplaceTemplateValues.mjsto avoid rendering a duplicate Table of Contents in the API documentation layout.Description
This change removes the extra Table of Contents picker rendered in the content header area of the generated API documentation pages.
The sidebar navigation already provides the full documentation index, so rendering another TOC picker in the page header created redundant navigation and unnecessary visual clutter.
This update removes:
__TOC_PICKER__placeholder from the HTML templatereplaceTemplateValues.mjsValidation
doc-kitRelated Issues
Fixes nodejs/node#60667
Check List
node --run testand all tests passed.node --run format&node --run lint.__TOC_PICKER__placeholder from the template and its corresponding generation logic inreplaceTemplateValues.mjsto avoid rendering a duplicate Table of Contents in the API documentation layout.