Source code of my website
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

๐Ÿ› : only display projects on first page

+8 -1
+8 -1
layouts/index.html
··· 1 1 {{ define "main" -}} 2 + 3 + {{ $pag := .Paginate (where .Site.RegularPages "Type" "in" "posts") }} 4 + 5 + {{/* only display projects on first page */}} 6 + {{ if eq $pag.PageNumber 1 }} 2 7 <h1>Projects</h1> 3 8 <div class="projects"> 4 9 {{ range (where .Site.RegularPages "Type" "projects").ByDate.Reverse }} ··· 6 11 {{ end }} 7 12 </div> 8 13 <hr/> 14 + {{ end }} 15 + 9 16 <h1>Posts</h1> 10 17 <div class="posts"> 11 - {{ range (.Paginate (where .Site.RegularPages "Type" "in" "posts")).Pages }} 18 + {{ range $pag.Pages }} 12 19 <article class="post"> 13 20 {{ partial "post/info.html" . }} 14 21 {{ if or (.Site.Params.noSummary) (.Params.noSummary) }}