mirror of
https://github.com/TrezOne/congo-hindi-gujarati.git
synced 2026-07-20 01:45:30 -04:00
🔀 Merge pull request #1046 from HactarCE/patch-canonical-url
✨ Add `canonicalUrl` parameter
This commit is contained in:
@@ -6,6 +6,10 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|||||||
|
|
||||||
## [Unreleased]
|
## [Unreleased]
|
||||||
|
|
||||||
|
### Added
|
||||||
|
|
||||||
|
- `canonicalUrl` parameter for article front matter ([#1046](https://github.com/jpanther/congo/pull/1046))
|
||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
|
|
||||||
- ⚠️ Required Hugo version is now 0.146.0 or later
|
- ⚠️ Required Hugo version is now 0.146.0 or later
|
||||||
|
|||||||
@@ -94,7 +94,11 @@
|
|||||||
{{ with .Params.robots }}
|
{{ with .Params.robots }}
|
||||||
<meta name="robots" content="{{ . }}" />
|
<meta name="robots" content="{{ . }}" />
|
||||||
{{ end }}
|
{{ end }}
|
||||||
<link rel="canonical" href="{{ .Permalink }}" />
|
{{ if .Params.canonicalUrl }}
|
||||||
|
<link rel="canonical" href="{{ .Params.canonicalUrl }}">
|
||||||
|
{{ else }}
|
||||||
|
<link rel="canonical" href="{{ .Permalink }}">
|
||||||
|
{{ end }}
|
||||||
{{ range .AlternativeOutputFormats -}}
|
{{ range .AlternativeOutputFormats -}}
|
||||||
{{ printf `<link rel="%s" type="%s" href="%s" title="%s" />` .Rel .MediaType.Type .RelPermalink ($.Site.Title | emojify) | safeHTML }}
|
{{ printf `<link rel="%s" type="%s" href="%s" title="%s" />` .Rel .MediaType.Type .RelPermalink ($.Site.Title | emojify) | safeHTML }}
|
||||||
{{ end -}}
|
{{ end -}}
|
||||||
|
|||||||
Reference in New Issue
Block a user