I seem to be missing the anchor links next to the headings, which allowed me to link to a specific section directly, for instance in this topic, like described in the start post:
Is this me or did this functionality disappear?
I seem to be missing the anchor links next to the headings, which allowed me to link to a specific section directly, for instance in this topic, like described in the start post:
Is this me or did this functionality disappear?
They should be there? I’m currently on my phone, but I grabbed this one by long-pressing on the gap to the side of the heading:
https://meta.discourse.org/t/discotoc-automatic-table-of-contents/111143#how-does-it-work-3
Yes, that topic has those anchor links, but that’s a topic that does not have the DiscoTOC.
But this topic has a TOC and does not have anchors: Beginner's guide to using Discourse Themes and this one does not have anchors either Setup DiscourseConnect - Official Single-Sign-On for Discourse (sso)
EDIT Hmm…this topic does have anchors: Discourse REST API Documentation
Ah, I can explain. The topic you linked has html headings (<h3>
, <h4>
and so on) and initially the TOC component had its own logic for adding heading anchors. However, since then, core added automatic anchors and recently I removed the custom anchor login in the theme component. However, core’s anchor feature only works for Markdown headings (using ###
).
So that’s the OP here has anchors, but the linked guide doesn’t.
We probably should update that guide to use Markdown instead of HTML @JammyDodger.
I was clearly not paying enough attention yesterday. I have now swopped in Markdown headers for the two example topics.
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
Topic | Replies | Views | Activity | |
---|---|---|---|---|
Linking to a heading within a post | 5 | 101 | January 5, 2025 | |
Cannot deep link to anchor in text | 6 | 1423 | December 17, 2021 | |
Anchors Not Working Across Posts Within Topic | 11 | 511 | October 1, 2022 | |
Inlink the topics within the same article | 4 | 1144 | June 22, 2020 | |
Handling anchors in posts created with markdown | 6 | 89 | June 15, 2025 |