I use knitr's spin() function to generate html reports.
Is there a way to make spin() generate a table of contents (toc) for headings embedded in the comments somehow?
(Note: I cannot use pandoc for that and have to use the markdown & html generator provided by knitr.)