Skip to content
Snippets Groups Projects
Commit 26c46e43 authored by Jannes Lücht's avatar Jannes Lücht :shark:
Browse files

:coffin: Nuke RSS capacites

parent 65a09d21
Branches
No related tags found
No related merge requests found
import rss from '@astrojs/rss';
import { getCollection } from 'astro:content';
import { SITE_TITLE, SITE_DESCRIPTION } from '../consts';
// import rss from '@astrojs/rss';
// import { getCollection } from 'astro:content';
// import { SITE_TITLE, SITE_DESCRIPTION } from '../consts';
export async function GET(context) {
const posts = await getCollection('blog');
return rss({
title: SITE_TITLE,
description: SITE_DESCRIPTION,
site: context.site,
items: posts.map((post) => ({
...post.data,
link: `/blog/${post.slug}/`,
})),
});
}
// export async function GET(context) {
// const posts = await getCollection('blog');
// return rss({
// title: SITE_TITLE,
// description: SITE_DESCRIPTION,
// site: context.site,
// items: posts.map((post) => ({
// ...post.data,
// link: `/blog/${post.slug}/`,
// })),
// });
// }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment