hugo-theme-relearn/layouts/partials/meta.html
2024-10-11 16:45:42 +02:00

21 lines
No EOL
1.3 KiB
HTML

<meta charset="utf-8">
{{- /* to avoid that user swiping to the left leaves a gap on the right side, we set minimum-scale, even if not advised to */}}
<meta name="viewport" content="height=device-height, width=device-width, initial-scale=1.0, minimum-scale=1.0">
{{- if (ne .Site.Params.disableGeneratorVersion true) }}
{{- $gen := hugo.Generator }}
{{- $gen = replaceRE "\\s*/>$" ">" $gen }}
{{ $gen | safeHTML }}
{{- $ver := partial "version.txt" }}
{{- $ver := printf "<meta name=\"generator\" content=\"%s %s\">" "Relearn" $ver }}
{{ $ver | safeHTML }}
{{- end }}
{{- if not (and .Title .RelPermalink (or (ne .Site.Params.disableSeoHiddenPages true) (not (partialCached "_relearn/pageIsHiddenSelfOrAncestor.gotmpl" (dict "page" . "to" .Site.Home) .Path .Site.Home.Path) ) ) ) }}
<meta name="robots" content="noindex, nofollow, noarchive, noimageindex">
{{- end }}
<meta name="description" content="{{ with trim (or .Description .Summary | plainify | htmlUnescape) "\n\r\t " }}{{ . }}{{ end }}">
{{- $authorName := partialCached "_relearn/authorName.gotmpl" . }}
<meta name="author" content="{{ $authorName }}">
{{- partial "twitter_cards.html" . }}
{{- partial "opengraph.html" . }}
{{- partial "schema.html" . }}