layouts: Use Permalink instead of RelPermalink

Addresses upstream multihost bug:
https://github.com/gohugoio/hugo/issues/12560

Closes #185
This commit is contained in:
Joe Mooring 2024-06-01 08:52:57 -07:00 committed by zjedi
parent e13ca197b8
commit b5c6238a1b
3 changed files with 6 additions and 6 deletions

View file

@ -7,5 +7,5 @@
--> -->
{{ $videoResource := resources.Get "cover/pexels-pressmaster-3209239-960x540-25fps.mp4" }} {{ $videoResource := resources.Get "cover/pexels-pressmaster-3209239-960x540-25fps.mp4" }}
<source src="{{ $videoResource.Permalink }}" type="video/mp4"> <source src="{{ $videoResource.RelPermalink }}" type="video/mp4">
</video> </video>

View file

@ -16,7 +16,7 @@
{{ $scriptPolyfill := resources.Get "js/css-vars-ponyfill.min.js" }} {{ $scriptPolyfill := resources.Get "js/css-vars-ponyfill.min.js" }}
{{ $js := slice $scriptJquery $scriptIcons $scriptIndex $scriptPolyfill | resources.Concat "js/script.js" | resources.Minify | resources.Fingerprint }} {{ $js := slice $scriptJquery $scriptIcons $scriptIndex $scriptPolyfill | resources.Concat "js/script.js" | resources.Minify | resources.Fingerprint }}
<script src="{{ $js.Permalink }}" integrity="{{ $js.Data.Integrity }}" ></script> <script src="{{ $js.RelPermalink }}" integrity="{{ $js.Data.Integrity }}" ></script>
<!-- activate css-vars-ponyfill.min.js --> <!-- activate css-vars-ponyfill.min.js -->
<script>cssVars();</script> <script>cssVars();</script>

View file

@ -4,7 +4,7 @@
<title>{{ with .Title }}{{ . }}{{ else }}{{ .Site.Title }}{{ end }}</title> <title>{{ with .Title }}{{ . }}{{ else }}{{ .Site.Title }}{{ end }}</title>
{{ with resources.Get .Site.Params.favicon }} {{ with resources.Get .Site.Params.favicon }}
<link rel="shortcut icon" href="{{ .Permalink }}" type="{{ .MediaType.Type }}" />{{ end }} <link rel="shortcut icon" href="{{ .RelPermalink }}" type="{{ .MediaType.Type }}" />{{ end }}
{{ with .Site.Params.description }} {{ with .Site.Params.description }}
<meta name="description" content="{{ . }}" <meta name="description" content="{{ . }}"
@ -26,7 +26,7 @@
{{ $stylesheetScreen := ( resources.Get "css/_index.scss" | resources.ToCSS ) }} {{ $stylesheetScreen := ( resources.Get "css/_index.scss" | resources.ToCSS ) }}
{{ $stylesheet := slice $stylesheetNormalize $stylesheetFA $stylesheetFonts $stylesheetGeneric $stylesheetScreen | resources.Concat "css/style.css" | resources.Minify | resources.Fingerprint }} {{ $stylesheet := slice $stylesheetNormalize $stylesheetFA $stylesheetFonts $stylesheetGeneric $stylesheetScreen | resources.Concat "css/style.css" | resources.Minify | resources.Fingerprint }}
<link rel="stylesheet" href="{{ $stylesheet.Permalink }}" type="text/css" integrity="{{ $stylesheet.Data.Integrity }}" /> <link rel="stylesheet" href="{{ $stylesheet.RelPermalink }}" type="text/css" integrity="{{ $stylesheet.Data.Integrity }}" />
{{ template "_internal/opengraph.html" . }} {{ template "_internal/opengraph.html" . }}
{{ template "_internal/twitter_cards.html" . }} {{ template "_internal/twitter_cards.html" . }}