Remove not required tailing slashes for `meta`, `link` (#862)

This commit is contained in:
Rotzbua 2022-03-31 20:03:56 +02:00 committed by GitHub
parent 363756ffee
commit 09921bb542
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 7 additions and 7 deletions

View File

@ -12,25 +12,25 @@
{{- /* Meta */}}
{{- if .IsHome }}
{{ with site.Params.keywords -}}<meta name="keywords" content="{{- range $i, $e := . }}{{ if $i }}, {{ end }}{{ $e }}{{ end }}" />{{ end }}
{{ with site.Params.keywords -}}<meta name="keywords" content="{{- range $i, $e := . }}{{ if $i }}, {{ end }}{{ $e }}{{ end }}">{{ end }}
{{- else }}
<meta name="keywords" content="{{ if .Params.keywords -}}
{{- range $i, $e := .Params.keywords }}{{ if $i }}, {{ end }}{{ $e }}{{ end }} {{- else }}
{{- range $i, $e := .Params.tags }}{{ if $i }}, {{ end }}{{ $e }}{{ end }} {{- end -}}" />
{{- range $i, $e := .Params.tags }}{{ if $i }}, {{ end }}{{ $e }}{{ end }} {{- end -}}">
{{- end }}
<meta name="description" content="{{- with .Description }}{{ . }}{{- else }}{{- if or .IsPage .IsSection}}
{{- .Summary | default (printf "%s - %s" .Title site.Title) }}{{- else }}
{{- with site.Params.description }}{{ . }}{{- end }}{{- end }}{{- end -}}">
<meta name="author" content="{{ (partial "author.html" . ) }}">
<link rel="canonical" href="{{ if .Params.canonicalURL -}} {{ trim .Params.canonicalURL " " }} {{- else -}} {{ .Permalink }} {{- end }}" />
<link rel="canonical" href="{{ if .Params.canonicalURL -}} {{ trim .Params.canonicalURL " " }} {{- else -}} {{ .Permalink }} {{- end }}">
{{- if site.Params.analytics.googlesiteVerificationTag }}
<meta name="google-site-verification" content="{{ site.Params.analytics.googlesiteVerificationTag }}" />
<meta name="google-site-verification" content="{{ site.Params.analytics.googlesiteVerificationTag }}">
{{- end }}
{{- if site.Params.analytics.yandexsiteVerificationTag }}
<meta name="yandex-verification" content="{{ site.Params.analytics.yandexsiteVerificationTag }}" />
<meta name="yandex-verification" content="{{ site.Params.analytics.yandexsiteVerificationTag }}">
{{- end }}
{{- if site.Params.analytics.bingsiteVerificationTag }}
<meta name="msvalidate.01" content="{{ site.Params.analytics.bingsiteVerificationTag }}" />
<meta name="msvalidate.01" content="{{ site.Params.analytics.bingsiteVerificationTag }}">
{{- end }}
{{- /* Styles */}}
@ -99,7 +99,7 @@
<link rel="{{ .Rel }}" type="{{ .MediaType.Type | html }}" href="{{ .Permalink | safeURL }}">
{{ end -}}
{{- range .AllTranslations -}}
<link rel="alternate" hreflang="{{ .Lang }}" href="{{ .Permalink }}" />
<link rel="alternate" hreflang="{{ .Lang }}" href="{{ .Permalink }}">
{{ end -}}
<noscript>