Add Table of Contents to wiki pages
I think this should be possible without too much effort. Most likely we can just parse the rendered HTML for <h1>
, <h2>
, etc. tags and generate a table of contents from those (probably storing it in the page's database record).
This will also involve adding id=
attrs to each of the tags so that they can be linked to with anchors.
Edited by Deimos