I've gotta dynamically render a Table of Contents for some Markdown content separate from the rest of the content. Is the best way to just crawl the rendered HTML and collect headers above a certain level or is there a better way to do that?
Eureka — Eleventy's rich ecosystem of plugins to the rescue. Looks like someone has already done what I was trying to, using Cheerio to parse HTML and everything.
github.com/jdsteinbach/eleventy-plugin-toc
(h/t GOAT
@zachleat
)