<nav id="post-nav">
    {{ if or (.Paginator.HasPrev) (.Paginator.HasNext) }}
        {{ if .Paginator.HasPrev }}
        <span class="prev">
            <a href="{{.Paginator.Prev.URL}}">
                <span class="arrow">←</span> {{ .Site.Params.newerPosts | default "Newer Posts" }}
            </a>
        </span>
        {{ end }}
        {{ if .Paginator.HasNext }}
        <span class="next">
            <a href="{{.Paginator.Next.URL}}">
                {{ .Site.Params.olderPosts | default "Older Posts" }}<span class="arrow">→</span>
            </a>
        </span>
        {{ end }}
    {{ end }}
</nav>
