feat: hide blog link if page not created (#4)

Allows this theme to be used for sites that do not have a blog.
master
Nick Badal 2 years ago committed by GitHub
parent 3d510363c7
commit dcff8a4f85
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      layouts/partials/nav.html

@ -2,4 +2,6 @@
{{ range .Site.Menus.main }}
<a href="{{ .URL }}">{{ .Name }}</a>
{{ end }}
{{ with .Site.GetPage "/blog" }}
<a href="{{ "/blog" | relURL }}">Blog</a>
{{ end }}