diff --git a/site/src/pages/rss.xml.js b/site/src/pages/rss.xml.js index 76f05ce4..46f236d2 100644 --- a/site/src/pages/rss.xml.js +++ b/site/src/pages/rss.xml.js @@ -4,7 +4,10 @@ import { SITE_DESCRIPTION, SITE_TITLE } from '@/consts'; // TODO cache idk this can be static export async function GET(context) { - const posts = await getCollection('blog'); + const posts = (await getCollection('blog')) + .filter((post) => !post.data.devOnly || import.meta.env.DEV) + .sort((a, b) => b.data.pubDate.valueOf() - a.data.pubDate.valueOf()); + return rss({ title: SITE_TITLE, description: SITE_DESCRIPTION,