commit e8ff782455641ae7ae5e4b38a48a5a69ca2b1e3d
parent 4ea563246623938d6ce5ed2149491e7099ad44a1
Author: Oscar Benedito <oscar@oscarbenedito.com>
Date: Wed, 29 Jul 2020 15:57:26 +0200
Fix atom feed links
Now only the list pages have them, and to the corresponding
tag/category.
Diffstat:
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html
@@ -2,9 +2,9 @@
<html lang="en">
<head>
{{ partial "head-base.html" . -}}
- <link rel="alternate" type="application/atom+xml" title="{{ .Site.Params.blog_title }}" href=/blog/index.xml>
{{- $style := resources.Get "css/style.scss" | toCSS | minify | fingerprint }}
<link id="theme" rel="stylesheet" type="text/css" href="{{ $style.RelPermalink }}">
+ {{- block "add-to-header" . }}{{ end }}
</head>
<body>
{{ partial "header.html" . }}
diff --git a/layouts/_default/list.html b/layouts/_default/list.html
@@ -1,3 +1,7 @@
+{{ define "add-to-header" }}
+<link rel="alternate" type="application/atom+xml" title="{{ .Site.Params.blog_title }}" href="{{ .RelPermalink }}index.xml">
+{{ end }}
+
{{ define "main" }}
<main class="list">
{{- if .Content }}