2020-08-05 17:14:10 +00:00
|
|
|
{{ define "title" }}
|
|
|
|
<title>{{ blog.Title }}</title>
|
|
|
|
{{ end }}
|
|
|
|
|
|
|
|
{{ define "main" }}
|
|
|
|
<main>
|
2020-09-01 16:14:49 +00:00
|
|
|
{{ with .Title }}<h1>{{ . }}</h1>{{ end }}
|
|
|
|
{{ with .Description }}{{ md . }}{{ end }}
|
|
|
|
{{ if (or .Title .Description) }}<hr>{{ end }}
|
2020-08-05 17:54:04 +00:00
|
|
|
{{ range $i, $post := .Posts }}
|
|
|
|
{{ include "summary" . }}
|
|
|
|
{{ end }}
|
|
|
|
{{ if .HasPrev }}
|
|
|
|
<p><a href="{{ .Prev }}">Prev</a></p>
|
|
|
|
{{ end }}
|
|
|
|
{{ if .HasNext }}
|
|
|
|
<p><a href="{{ .Next }}">Next</a></p>
|
|
|
|
{{ end }}
|
2020-08-05 17:14:10 +00:00
|
|
|
</main>
|
|
|
|
{{ end }}
|
|
|
|
|
|
|
|
{{ define "index" }}
|
|
|
|
{{ template "base" . }}
|
|
|
|
{{ end }}
|