allow dublicate headlines in toc extension#51
Conversation
Adds a random hash to the id and link of each heading in the toc extension.
|
This shouldn't be done unconditionally. It should probably only add this suffix in the event of a collision, and even then, it should probably use a counter instead of a random hash that will be different on every page load. |
|
See also here: jupyter/notebook#77 -> This breaks if one uses internal (head of the notebook to somewhere down) or external links (nbviewer) links to headlines. |
|
@JanSchulz exactly. Deduplicating with counters iff there is a colision will work better than UUIDs that may or may not be stable. |
|
Counters aren't stable as well, when I add a new headline in between or before :-( |
|
I havn't thought about the internal/external linking so far. Regarding the internal/external linking: if you think about LaTeX one needs some anchors/labels to do so and the actual TOC there is still build automatically from the structure/level of the headings. |
Adds a random hash to the id and link of each heading in the toc
extension.