Verified Commit 5d81589a authored by JohnMH's avatar JohnMH

Add breadcrumbs

parent 00f9c3dd
Pipeline #2647 passed with stages
in 12 seconds
......@@ -6,6 +6,9 @@ theme = "JohnMH"
uglyURLs = true
enableGitInfo = true
enableRobotsTXT = true
pygmentsCodefences = true
pygmentsStyle = "solarized-dark"
pygmentsOptions = "linenos=table"
[outputs]
home = ["HTML"]
......
---
linktitle: "Home"
---
## Hello!
Hi, I'm John M. Harris, Jr. I'm a software developer, network
......
---
title: John's Blog
linktitle: "Blog"
---
<h1>John's Blog</h1>
<p>A blog about software, electronics and opinions. Mostly opinions.</p>
<hr/>
<ol class="breadcrumbs">
{{ template "breadcrumbnav" (dict "p1" . "p2" .) }}
</ol>
{{ define "breadcrumbnav" }}
{{ if .p1.Parent }}
{{ template "breadcrumbnav" (dict "p1" .p1.Parent "p2" .p2 ) }}
{{ else if not .p1.IsHome }}
{{ template "breadcrumbnav" (dict "p1" .p1.Site.Home "p2" .p2 ) }}
{{ end }}
<li{{ if eq .p1 .p2 }} class="active"{{ end }}>
<a href="{{ .p1.Permalink }}">{{ .p1.LinkTitle }}</a>
</li>
{{ end }}
<hr/>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment