planblog/layouts/partials/pagination.html

12 lines
351 B
HTML

<nav class="pagination" role="navigation">
{{ if or .HasPrev .HasNext }}
<hr />
{{ end }}
{{if .HasPrev}}
<a class="newer-posts" href="{{ .Prev.URL }}"><span aria-hidden="true">&laquo;</span> Newer Posts</a>
{{end}}
{{if .HasNext}}
<a class="older-posts" href="{{ .Next.URL }}">Older Posts <span aria-hidden="true">&raquo;</span></a>
{{end}}
</nav>