Streaming live at 10am (PST)

Dynamic Table of contents

I have a webflow site that has about 20 support articles, these are standard pages. Is it possible to use a TOC generator, everything I have raid seems to require CMS. Essentially I just want to create anchors within a menu for all headings with a particular style class.

The term “dynamic” is used as the opposite of “static” and especially refers to the use of a CMS.

So you want a dynamic property on your static pages. That’s not uncommon, there are ways to ease the process, maybe.

You want a TOC on each of your article pages, where each entry points to a section down the article. i don’t see a way of making that automatic, however you can try to streamline it a bit.

I would start by using the same set of anchors names (which are IDs) for each article, and start by declaring all the IDs on all the articles. I would use names like “section-1”, “section-2” etc. Avoid using spaces (just an advice), and don’t make the ID start by a number (that’s mandatory).

Then on one page I’d manually build my TOC block, copying and pasting the headings of the sections where I had put an ID, and manually linking each entry of the TOC to its appropriate section.

This way, you can now copy and paste the TOC block on the other articles. You will have to manually update the text of each TOC entry, but you won’t have to link them again, because you have used the same IDs on each article.

Not the solution you’re looking for but a bit of a technique.

Thanks you so much I’ll have a play.

Note that this is a quite very feasible feature to develop in Javascript. You could just design the TOC block and ask a JS dev to create it on the fly for each page using your layout and style (i.e. the script would look for every H2 heading, add an ID and create an entry on the TOC, that’s what JS is made for).

Hi Vincent,

Thanks you so much.

I found this - which is exactly what I am looking for. Is there a good spot to look for a webflow / JS developer to help on this, it is above my pay grade.

Thanks again,


There’s a freelance category right here, and there’s also

Hi @Ross_Layton1! Just in case you didn’t manage to solve this yet, I wrote a tutorial on how to achieve what @vincent described.

Hope this helps :slight_smile:

1 Like