How to get all Post of a specific Param.categories

Is it possible to get all the Posts of a specific Param.categories

{{ range where .Data.Pages ".Params.categories" .eq. "Labs" }}

{{content}}

1 Like

I have tried this as well, and it doesn’t work
{{ range .Site.Pages}}
{{if in .Params.categories “Labs” }}
{{ partial “content.html” . }}
{{end}}
{{end}}

I got this working, not sure what I was doing wrong. I still don’t understand the difference between .Site.Pages and .Data.Pages, both seem to work

    {{ range .Site.Pages}}
        {{ if in .Params.categories "lab" }}
          {{ partial "labs.html" . }}
        {{end}}
      {{end}}
1 Like
1 Like