mirror of
https://github.com/adityatelange/hugo-PaperMod.git
synced 2023-12-21 10:22:58 +01:00
head: Fix user defining canonical URL resulting in multiple canonical URLs (#133)
* Revert "head: add support for Canonical URLs"
This reverts commit 8af7c551ff
.
* Allow user to specify single canonical URL
This commit is contained in:
parent
77ff1e6b45
commit
2abc278c69
@ -16,11 +16,7 @@
|
||||
{{- .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="{{ .Permalink }}" />
|
||||
{{- $canonical := cond (.IsHome) .Site.Params.canonical .Params.canonical }}
|
||||
{{- range $canonical }}
|
||||
<link rel="canonical" href="{{ trim . " " }}" />
|
||||
{{- end }}
|
||||
<link rel="canonical" href="{{ if .Params.canonicalURL -}} {{ .Params.canonicalURL }} {{- else -}} {{ .Permalink }} {{- end }}" />
|
||||
{{- if .Site.Params.analytics.google.SiteVerificationTag }}
|
||||
<meta name="google-site-verification" content="{{ .Site.Params.analytics.google.SiteVerificationTag }}" />
|
||||
{{- end}}
|
||||
|
Loading…
Reference in New Issue
Block a user