summaryrefslogtreecommitdiff
path: root/layouts/_default/list.html
blob: 7d0aba7c5fbfa28d86a696bd3901f6b950a1fc7b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
{{ partial "header.html" . }}
<div style="display: block;">
    <div class="container">
        <h2>Recent posts</h2>
        <div class="content-wrapper">

            {{ .Content }}

            <ul class="content-list">
                {{ $pages := .Pages }}
                {{ $pages = .Site.RegularPages }}
                {{ if .IsHome }}
                    {{ range (where $pages "Section" "==" "posts") }}
                {{ else }} 
                    {{ range (where $pages "Section" "==" "books") }}
                {{ end }}

                <li>
                    <span class="date">{{ .Date.Format "2006/01/02" }}</span>
                    <a href="{{ .RelPermalink }}">{{ .Title | markdownify }}</a>
                </li>
                {{ end }}
            </ul>
        </div>
    </div>
</div>
{{ partial "footer.html" . }}