Iterating over lists in Bridgetown Frontmatter

While building this site using Bridgetown, I bumped into an issue.


I wanted to create lists in the frontmatter of each item in a collection. For my “projects” collection, I wanted a list of tags. And then in the HTML, I wanted to iterate over each tag and display it as a badge.


I tried a couple different ways to fix this but nothing was working, until I found a solution.


My frontmatter looks like this:

- elixir
- mapping


And in my view I have:

 for tag in


It seems simple but I couldn’t find this in the docs anywhere so I wanted to share. Hope it helps!

Subscribe to updates