I have two main content types on my blog. There are posts and river. Posts are long format while river is just random things I post more regularly. I want the homepage to show only the posts. I cannot get this to work with pagination. I either get empty slots on the page for filtered river items or all items show up. The code below is the partial I use for the main homepage. It currently pulls all items regardless of type although I thought it should filter the posts. Any help would be appreciated. I’m at a loss.
{{ define "main" }}
{{ $pages := where site.RegularPages "Type" "posts" }}
{{ range (.Paginate $pages).Pages }}
<article class="post-list">
<header>
<h1>
{{ .Title }}
</h1>
</header>
<div class="content">
{{ .Content }}
</div>
{{ partial "articleInfoFull.html" . }}
</article>
{{ end }}
{{ partial "pagination.html" . }}
{{ end }}
. Thank you for your help.