allow dublicate headlines in toc extension - #51
Conversation
Adds a random hash to the id and link of each heading in the toc extension.
minrk
commented
Sep 8, 2015
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. |
jankatins
commented
Sep 8, 2015
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. |
minrk
commented
Sep 8, 2015
@JanSchulz exactly. Deduplicating with counters iff there is a colision will work better than UUIDs that may or may not be stable. |
jankatins
commented
Sep 8, 2015
Counters aren't stable as well, when I add a new headline in between or before :-( |
dschick
commented
Sep 9, 2015
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.