Skip to content

Commit

Permalink
Set up list.html
Browse files Browse the repository at this point in the history
Fixes #1
  • Loading branch information
BBaoVanC committed Sep 26, 2021
1 parent 03eb50c commit 49622c0
Showing 1 changed file with 37 additions and 0 deletions.
37 changes: 37 additions & 0 deletions layouts/_default/list.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
{{ define "main" }}
{{ if .Data.Singular }}
<h3>Filtering for "{{ .Title }}"</h3>
<small>
<a href="{{ . | relURL }}">Remove filter</a>
</small>
{{ else }}
<h1>{{ .Title }}</h1>
{{ end }}
<ul>
{{ range .Pages }}
<li>
{{ if .Date }}
<time datetime="{{ .Date.Format "2006-01-02" }}" pubdate>
{{ .Date.Format "2006-01-02" }}
</time>
{{ end }}
<a href="{{ .Permalink }}">{{ .Title }}</a>
</li>
{{ else }}
<li>
No posts here!
</li>
{{ end }}
</ul>
{{ if .Data.Singular }}
{{ else }}
<small>
Site-wide tags:
<div>
{{ range .Site.Taxonomies.tags }}
<a href="{{ .Page.Permalink }}">#{{ .Page.Title }}</a>&nbsp;
{{ end }}
</div>
</small>
{{ end }}
{{ end }}

0 comments on commit 49622c0

Please sign in to comment.