I know it’s possible to filter pages by frontmatter, but I cannot seem to get it to work with a parameter containing an array. E.g. think of the following front matter:
+++
featured = ["local", "elsewhere"]
+++
With all that I read up on the forums and documentation, I should be able to filter for a certain value like:
{{ range where .Site.Pages.ByWeight ".Params.featured" "in" (slice "local") }}
I tried all kinds of combinations with intersect or "in" "local" but I always get an empty result.
Am I missing something obvious?
Thanks for the hint! I’ve stumbled upon this thread, but got lost after a few messages. This might indeed work for my use case, but it looks a bit cumbersome and I wonder whether I’m working against the Hugo core design.