diff options
| author | Ariel Costas Guerrero <94913521+arielcostas@users.noreply.github.com> | 2025-03-14 23:33:56 +0100 |
|---|---|---|
| committer | Ariel Costas Guerrero <94913521+arielcostas@users.noreply.github.com> | 2025-03-14 23:33:56 +0100 |
| commit | e3c4bb2efa513973bc26949a8be62fbe66e31a4f (patch) | |
| tree | 75a46cbde3ec2d36cfd33bff63ae7c65d145c182 /src/pages/blog.xml.ts | |
| parent | 54dab1e00b38693e96c801d0c5a020693a35bbda (diff) | |
Implement new page layouts for Home, Contact, Portfolio, and Trajectory; update header and footer for multilingual support
Diffstat (limited to 'src/pages/blog.xml.ts')
| -rw-r--r-- | src/pages/blog.xml.ts | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/src/pages/blog.xml.ts b/src/pages/blog.xml.ts new file mode 100644 index 0000000..f165475 --- /dev/null +++ b/src/pages/blog.xml.ts @@ -0,0 +1,19 @@ +import rss from '@astrojs/rss'; +import { getCollection } from 'astro:content'; + + +export async function GET(context: any) { + const collection = await getCollection('blog'); + + return rss({ + title: "Blog de Ariel Costas", + description: "ArtÃculos del blog de Ariel Costas", + site: context.site, + items: collection.map((post: any) => ({ + title: post.data.title, + link: `${context.site}blog/${post.slug}`, + description: post.data.metaDescription, + pubDate: post.data.publishedAt + })) + }) +} |
