I created a bookmarklet to create the table of content for forum posts

Thank you for the replies :slight_smile:

As @Lhc_fl says, the DOM appreach (HTML/JavaScript) is limited in the number of items we can manage. Discourse API might help for such actions.
Another problem with creating TOC for replies is that it’s not easy to define what would be the heading title for each reply. We could use information like the author and the date, but I’m not sure how it’s more useful than the existing scrolling progress bar.

Thank you @mcwumbly!