Having just swapped some messages with @kaushalmodi in another post about RSS feeds, I thought that I ought to share my own RSS/ATOM template for ridicule by all:
{{/***
* Override the Hugo RSS feed default as that only shows a summary of the post,
* not the whole article which is what most people really want.
* Includes the page .Description as well as the .Content as this typically
* contains different text.
***/}}
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
<channel>
<title>{{ if eq .Title .Site.Title }}{{ .Site.Title }}{{ else }}{{ with .Title }}{{.}} on {{ end }}{{ .Site.Title }}{{ end }}</title>
<link>{{ .Permalink }}</link>
<description>
Recent content {{ if ne .Title .Site.Title }}{{ with .Title }}about {{.}} {{ end }}{{ end }}from {{ .Site.Title }} |
{{ with $.Site.Params.Description }}{{ . }}{{ end }}
</description>
<generator>Hugo | gohugo.io | Theme twenty-sixteen</generator>
{{- with .Site.LanguageCode -}}<language>{{.}}</language>{{end}}
{{- with .Site.Author.email -}}<managingEditor>{{.}}{{ with $.Site.Author.name }} ({{.}}){{end}}</managingEditor>{{end}}
{{- with .Site.Author.email -}}<webMaster>{{.}}{{ with $.Site.Author.name }} ({{.}}){{end}}</webMaster>{{end}}
{{- with .Site.Copyright -}}<copyright>{{.}}</copyright>{{end}}
{{- if not .Date.IsZero -}}<lastBuildDate>{{ now.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }}</lastBuildDate>{{ end }}
{{ with .OutputFormats.Get "RSS" }}
{{ printf "<atom:link href=%q rel=\"self\" type=%q />" .Permalink .MediaType | safeHTML }}
{{ end }}
{{ range .Data.Pages }}
<item>
<title>{{ .Title }}</title>
<link>{{ .Permalink }}</link>
<pubDate>{{ .Date.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }}</pubDate>
{{ with .Site.Author.email }}<author>{{.}}{{ with $.Site.Author.name }} ({{.}}){{end}}</author>{{end}}
<guid>{{ .Permalink }}</guid>
{{/* JK: 2018-04-08 Change .Summary to .Content to get full text */}}
{{/* JK: 2018-05-08 Add .description to content */}}
<description><div>{{ .Description | html }}</div><div>{{ .Content | html }}</div></description>
{{/* JK: 2018-04-08 Add post author */}}
<author>{{ .Params.Author | default .Site.Params.author }}</author>
{{- range .Params.categories -}}{{/* JK: 2018-04-08 Add category list */}}
<category domain="{{ $.Site.BaseURL }}/categories/{{ . | urlize }}">{{ .}}</category>
{{ end }}
</item>
{{ end }}
</channel>
</rss>
I have this in layouts/_default/rss.xml
in the twenty-sixteen theme that I’m using on my blog.
It is a copy of the template from the Hugo Docs with amendments as documented in the code comments.
Note that I use the page description meta visibly at the top of the page so the content is complementary to it which is why I want it to also appear in the feed. I will probably make this optional in the theme when I get round to it.