From 52ca7fafb0c4c1b81fc153c1c65edee6075d2fbd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Joshua=20St=C3=BCbner?= Date: Tue, 3 Aug 2021 14:18:25 +0200 Subject: [PATCH] Improve Collection docs for RSS (#990) - Added missing but required link attribute - Added note on how to create a full text feed --- docs/src/pages/core-concepts/collections.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/docs/src/pages/core-concepts/collections.md b/docs/src/pages/core-concepts/collections.md index edf4cf1fa..ef209e8a4 100644 --- a/docs/src/pages/core-concepts/collections.md +++ b/docs/src/pages/core-concepts/collections.md @@ -245,6 +245,7 @@ export async function createCollection() { }, rss: { title: 'My RSS Feed', + // if you want a full text feed, add your markup here (e.g. item.astro.html) description: 'Description of the feed', // (optional) add xmlns:* properties to root element xmlns: { @@ -260,7 +261,10 @@ export async function createCollection() { description: item.description, // enforce GMT timezone (otherwise it'll be different based on where it's built) pubDate: item.pubDate + 'Z', - // custom data is supported here as well + // link is required, shows up in RSS readers + link: '/collection/' + item.id + // (optional) custom data is supported here as well + customData: ``${Astro.site}collection/${item.id}`` }), }, };