hugo-internet-weblog/layouts/partials/page_header.html
Ghyslain Leclerc db12d07cb6 Using .URL in menu items instead of .Permalink
Using .Permalink was causing my site to not compile anymore with version 0.59.1
of Hugo.  According to this issue on the Hugo Github repository:

   https://github.com/gohugoio/hugo/issues/5868

in menus, .URL is not deprecated and can/should be kept.
2019-11-26 20:58:18 -05:00

30 lines
841 B
HTML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<header>
<nav>
<h1><a href="/">@{{ .Site.Author.handle }}</a>s {{ .Site.Title }}.</h1>
<div class="menu">
{{ if isset .Site.Params "rsssections" }}
{{ $.Scratch.Add "sections" .Site.Params.rsssections }}
<ul>
{{ range .Site.Menus.main }}
<li>
<a href="{{.URL}}">{{ .Name }}</a>
{{ if in ($.Scratch.Get "sections") .Name }}
<a href="{{.URL}}index.xml"><img src="/img/rss.svg" class="rss-icon" /></a>
{{ end }}
</li>
{{ end }}
{{ with .Site.Author.aboutpage }}<li><a href="{{ . }}">About</a></li>{{ end }}
</ul>
{{ else }}
<ul>
{{ range .Site.Menus.main }}
<li>
<a href="{{.URL}}">{{ .Name }}</a>
</li>
{{ end }}
{{ with .Site.Author.aboutpage }}<li><a href="{{ . }}">About</a></li>{{ end }}
</ul>
{{ end }}
</div>
</nav>
</header>