-
Notifications
You must be signed in to change notification settings - Fork 30.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
doc: buffer TOC incorrectly contains brackets #9331
Comments
Reverting fcee4d4 does not fix it. Must be something else. |
I found a way to fix the HTML generation so that the links will be visible. But the problem is, each and every part of the link will be pointing to different things. "What makes" will point to the actual section, |
If there is a link in the headings, when the ToC is generated, that is not properly linked and the square brackets are left as they are. Even if we fix this, different parts of the heading will link to different sections or even different pages. For example, ### What makes [`Buffer.allocUnsafe()`] and [`Buffer.allocUnsafeSlow()`] "unsafe"? will point to three different sections. `allocUnsafe` and `allocUnsafeSlow` will link to their corresponding sections and all other words actually link to the heading in the document. This could be visually confusing. Fixes: nodejs#9331
If there is a link in the headings, when the ToC is generated, that is not properly linked and the square brackets are left as they are. Even if we fix this, different parts of the heading will link to different sections or even different pages. For example, ### What makes [`Buffer.allocUnsafe()`] and [`Buffer.allocUnsafeSlow()`] "unsafe"? will point to three different sections. `allocUnsafe` and `allocUnsafeSlow` will link to their corresponding sections and all other words actually link to the heading in the document. This could be visually confusing. PR-URL: #9416 Fixes: #9331 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Minwoo Jung <jmwsoft@gmail.com> Reviewed-By: Roman Reiss <me@silverwind.io> Reviewed-By: Brian White <mscdex@mscdex.net>
If there is a link in the headings, when the ToC is generated, that is not properly linked and the square brackets are left as they are. Even if we fix this, different parts of the heading will link to different sections or even different pages. For example, ### What makes [`Buffer.allocUnsafe()`] and [`Buffer.allocUnsafeSlow()`] "unsafe"? will point to three different sections. `allocUnsafe` and `allocUnsafeSlow` will link to their corresponding sections and all other words actually link to the heading in the document. This could be visually confusing. PR-URL: #9416 Fixes: #9331 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Minwoo Jung <jmwsoft@gmail.com> Reviewed-By: Roman Reiss <me@silverwind.io> Reviewed-By: Brian White <mscdex@mscdex.net>
In the
buffer
doc TOC there is an entry called 'What makes [Buffer.allocUnsafe()] and [Buffer.allocUnsafeSlow()] "unsafe"?'. The brackets there should not be visible. The brackets do not exist in the v4.x docs. If I had to take a wild guess I would say the brackets were introduced when the 'deprecated' tags were added to every doc pages' TOC, as that is the immediate obvious difference between thebuffer
doc TOC in v4.x and v6.x/latest.The text was updated successfully, but these errors were encountered: