kramed icon indicating copy to clipboard operation
kramed copied to clipboard

Append identical header ids with counter

Open emilbayes opened this issue 9 years ago • 1 comments

This ensures unique HTML id's in line with the HTML spec, and allows anchors to always reference the intended header.

Fixes #27

emilbayes avatar Sep 20 '15 18:09 emilbayes

Not that this change will break another test that has two identical headers. It is also not finished, since the instance of Renderer persists across blobs of Markdown, and therefore the counters do not get reset. However looking at renderer.js it doesn't hold much state, and probably would be cheap to instantiate anew for each Markdown blob.

emilbayes avatar Sep 20 '15 18:09 emilbayes