If a blog article has a canonical URI set, link to it

This change lets us point search engines to the original article when we
mirror them from https://k8s.dev/ and potentially from other sites too.
This commit is contained in:
Tim Bannister
2020-10-01 17:47:45 +01:00
parent 1addb85433
commit 43a7be6495
+3
View File
@@ -4,6 +4,9 @@
{{ partial "head.html" . }}
<title>{{ if .IsHome }}{{ .Site.Title }}{{ else }}{{ with .Title }}{{ . }} | {{ end }}{{ .Site.Title }}{{ end }}</title>
<script defer src="https://use.fontawesome.com/releases/v5.0.6/js/all.js"></script>
{{ with .Params.canonicalUrl }}
<link rel="canonical" href="{{ . }}">
{{ end }}
</head>
<body class="td-{{ .Kind }} td-blog">
<header>