1
0
mirror of https://github.com/alanorth/hugo-theme-bootstrap4-blog.git synced 2024-11-24 13:10:18 +01:00

Support baseurl without trailing slash

This commit is contained in:
TommySprat 2019-06-04 00:26:09 +02:00
parent c17a7d229f
commit 8da12539f3
3 changed files with 6 additions and 6 deletions

View File

@ -14,10 +14,10 @@
{{ if eq .Lang "ar" }}
{{ "<!-- ar -->" | safeHTML }}
<link href="{{ .Site.BaseURL }}css/style.rtl.css" rel="stylesheet"{{ if not .Site.Params.disable_sri }} integrity="{{ .Site.Data.sri.styleltr}}" crossorigin="anonymous"{{ end }}>
<link href="{{ "css/style.rtl.css" | absURL }}" rel="stylesheet"{{ if not .Site.Params.disable_sri }} integrity="{{ .Site.Data.sri.styleltr}}" crossorigin="anonymous"{{ end }}>
{{ else }}
{{ "<!-- combined, minified CSS -->" | safeHTML }}
<link href="{{ .Site.BaseURL }}css/style.css" rel="stylesheet"{{ if not .Site.Params.disable_sri }} integrity="{{ .Site.Data.sri.style}}" crossorigin="anonymous"{{ end }}>
<link href="{{ "css/style.css" | absURL }}" rel="stylesheet"{{ if not .Site.Params.disable_sri }} integrity="{{ .Site.Data.sri.style}}" crossorigin="anonymous"{{ end }}>
{{ end }}
{{ "<!-- RSS 2.0 feed -->" | safeHTML }}
@ -55,7 +55,7 @@
{{ if (ne .Site.Params.header_visible false) }}
<header class="blog-header">
<div class="container">
<h1 class="blog-title" dir="auto"><a href="{{ .Site.BaseURL }}" rel="home">{{ .Site.Title | safeHTML }}</a></h1>
<h1 class="blog-title" dir="auto"><a href="{{ "/" | absURL }}" rel="home">{{ .Site.Title | safeHTML }}</a></h1>
{{ if .Site.Params.description }}<p class="lead blog-description" dir="auto">{{ .Site.Params.description | markdownify }}</p>{{ end }}
</div>
</header>

View File

@ -1,5 +1,5 @@
<link href="{{ .Site.BaseURL }}css/cookieconsent.min.css" rel="stylesheet" type="text/css"{{ if not .Site.Params.disable_sri }} integrity="{{ .Site.Data.sri.cookieconsentcss }}" crossorigin="anonymous"{{ end }}>
<script src="{{ .Site.BaseURL }}js/cookieconsent.min.js"{{ if not .Site.Params.disable_sri }} integrity="{{ .Site.Data.sri.cookieconsentjs }}" crossorigin="anonymous"{{ end }} async></script>
<link href="{{ "css/cookieconsent.min.css" | absURL }}" rel="stylesheet" type="text/css"{{ if not .Site.Params.disable_sri }} integrity="{{ .Site.Data.sri.cookieconsentcss }}" crossorigin="anonymous"{{ end }}>
<script src="{{ "js/cookieconsent.min.js" |absURL }}"{{ if not .Site.Params.disable_sri }} integrity="{{ .Site.Data.sri.cookieconsentjs }}" crossorigin="anonymous"{{ end }} async></script>
<script>
window.addEventListener("load", function(){

View File

@ -1,3 +1,3 @@
Sitemap: {{ .Site.BaseURL }}sitemap.xml
Sitemap: {{ "sitemap.xml" | absURL }}
User-agent: *