refactor(theme): replace $.Site.BaseURL with /

no reason not to in this case
pull/1/head
steven 2021-09-16 09:00:40 -04:00
parent c5aefd9d0b
commit a7d18d59a2
5 changed files with 11 additions and 11 deletions

View File

@ -1,11 +1,11 @@
{{ define "main" }}
<div class="row">
{{ range .Params.categories }}
<a href="{{ $.Site.BaseURL }}categories/{{ . | urlize }}/">{{ . }}</a>
<a href="/categories/{{ . | urlize }}/">{{ . }}</a>
{{ end }}
</div>
<article class="row content" style="margin-top: 20%">
<article class="row content" style="margin-top: 2em">
{{ .Content }}
</article>
@ -14,7 +14,7 @@
<p>
<span>Tagged: </span>
{{ range .Params.tags }}
<a href="{{ $.Site.BaseURL }}tags/{{ . | urlize }}/" class="tag">#{{ . }}</a>
<a href="/tags/{{ . | urlize }}/" class="tag">#{{ . }}</a>
{{ end }}
</p>
</div>

View File

@ -7,14 +7,14 @@
{{ range $paginator.Pages }}
<div class="five columns">
{{ range .Params.categories }}
<a href="{{ $.Site.BaseURL }}categories/{{ . | urlize }}/">{{ . }}</a>
<a href="/categories/{{ . | urlize }}/">{{ . }}</a>
{{ end }}
<h2><a href="{{ .Permalink }}">{{ .Title }}</a></h2>
<p class="date">{{.Date.Format "January 2, 2006"}}</p>
<p class="summary">{{ .Summary | plainify | htmlUnescape }}</p>
<p>
{{ range .Params.tags }}
<a href="{{ $.Site.BaseURL }}tags/{{ . | urlize }}/">#{{ . }}</a>
<a href="/tags/{{ . | urlize }}/">#{{ . }}</a>
{{ end }}
</p>
</div>

View File

@ -7,13 +7,13 @@
{{ range $paginator.Pages }}
<div class="five columns">
{{ range .Params.categories }}
<a href="{{ $.Site.BaseURL }}categories/{{ . | urlize }}/">{{ . }}</a>
<a href="/categories/{{ . | urlize }}/">{{ . }}</a>
{{ end }}
<h2><a href="{{ .Permalink }}">{{ .Title }}</a></h2>
<p class="summary">{{ .Summary | plainify | htmlUnescape }}</p>
<p>
{{ range .Params.tags }}
<a href="{{ $.Site.BaseURL }}tags/{{ . | urlize }}/">#{{ . }}</a>
<a href="/tags/{{ . | urlize }}/">#{{ . }}</a>
{{ end }}
</p>
</div>

View File

@ -1,7 +1,7 @@
<hr/>
<div class="row">
<ul class="nav">
<li class="mb-1"><a href="{{ .Site.BaseURL }}" class="text-secondary">home</a></li>
<li class="mb-1"><a href="/" class="text-secondary">home</a></li>
{{ range .Site.Menus.main }}
<li class="mb-1"><a href="{{ .URL }}" class="text-secondary">{{ .Name }}</a></li>
{{ end }}

View File

@ -10,9 +10,9 @@
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@300;400;600&display=swap" rel="stylesheet">
<link rel="stylesheet" href="{{ $.Site.BaseURL }}css/normalize.css">
<link rel="stylesheet" href="{{ $.Site.BaseURL }}css/skeleton.css">
<link rel="stylesheet" href="/css/normalize.css">
<link rel="stylesheet" href="/css/skeleton.css">
<link rel="icon" type="image/png" href="{{ $.Site.BaseURL }}images/favicon.png">
<link rel="icon" type="image/png" href="/images/favicon.png">
</head>