A recent post in the MadCap forums addressed the question of putting a mini-TOC-like object at the beginning of a topic to show all the headings on the actual page.
In the past, pharmacy I (like many of you, dosage I assume) have tried to do this using a mini-TOC proxy in Flare. We then discovered that the mini-TOC proxy only shows TOPICS that are beneath the current topic in the TOC that this topic is a part of. In essence, visit this a mini-TOC proxy is useful at the beginning of a chapter, so you can point out all the topics that are in the chapter. Among other things, this gives you content on the container topic in the TOC that begins the new chapter, which makes breadcrumbs and side-menus (in TopNav output) work.
The problem is that this doesn’t actually answer the original question. I want a dynamically-generated list of headings that are in the current topic.
The only thing I’ll add to Dave’s answer is the idea that you might not want to have this feature on every page in your content; maybe you want to apply this to specific pages or types of pages in your documentation. In that case, you’ll want to create this in its own masterpage that you can apply to topics that should use it. That way it isn’t an all-or-nothing decision.
Dave Lee blogs about MadCap Flare, and specifically about scripting hacks he’s created for Flare at https://ukauthor.wordpress.com/. Check out his site for other cool scripts you can add to your Flare projects.