Only include the HTML alternate link

This commit is contained in:
Will Faught
2023-09-20 23:37:58 -07:00
parent 9c42631c14
commit 54c4b70cbc
2 changed files with 4 additions and 8 deletions

View File

@@ -14,10 +14,8 @@
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
<channel>
{{ printf `<atom:link href="%s" rel="self" type="application/rss+xml"/>` ($page.Permalink | safeURL) | safeHTML }}
{{ range $page.AlternativeOutputFormats }}
{{ if eq .Rel "alternate" }}
{{ printf `<atom:link href="%s" rel="alternate" type="%s"/>` (.Permalink | safeURL) .MediaType | safeHTML }}
{{ end }}
{{ with $page.AlternativeOutputFormats.Get "html" }}
{{ printf `<atom:link href="%s" rel="alternate" type="%s"/>` (.Permalink | safeURL) .MediaType | safeHTML }}
{{ end }}
{{ with site.Copyright }}
<copyright>{{ . }}</copyright>