cabotia / cabotia.dev/ layouts/_default/list.htmla038d85870abfa5840f549c944fe88149c867b17
502 B | 23 lines Raw
1
{{ define "main" }}
2
	{{ $dateFormat := i18n "date.format" }}
3
	<h1>{{ .Title }}</h1>
4
	{{ .Content }}
5

6
	{{ range .Pages.ByDate.Reverse }}
7
		<article>
8
			<h2>
9
				<a href="{{ .RelPermalink }}">{{ .Title }}</a>
10
			</h2>
11

12
			{{ if not .Date.IsZero }}
13
				<p class="post-meta">
14
					<time datetime="{{ .Date.Format "2006-01-02" }}">{{ .Date.Format $dateFormat }}</time>
15
				</p>
16
			{{ end }}
17

18
			{{ with .Summary }}
19
				<p>{{ . | plainify | truncate 240 }}</p>
20
			{{ end }}
21
		</article>
22
	{{ end }}
23
{{ end }}