Home / File/ rss.xml.js — astro Source File

rss.xml.js — astro Source File

Architecture documentation for rss.xml.js, a javascript file in the astro codebase. 3 imports, 0 dependents.

File javascript CoreAstro RoutingSystem 3 imports 1 functions

Entity Profile

Dependency Diagram

graph LR
  6643ef7b_3cd4_fdee_9d10_a5ab9a414fe7["rss.xml.js"]
  0d04bf4e_57a4_ce8b_a5a7_40ca287fbcfe["consts.ts"]
  6643ef7b_3cd4_fdee_9d10_a5ab9a414fe7 --> 0d04bf4e_57a4_ce8b_a5a7_40ca287fbcfe
  48f80d01_e646_3924_78f6_a9d836644746["astro:content"]
  6643ef7b_3cd4_fdee_9d10_a5ab9a414fe7 --> 48f80d01_e646_3924_78f6_a9d836644746
  f22cdbe4_1771_9397_474b_361d2685b75b["rss"]
  6643ef7b_3cd4_fdee_9d10_a5ab9a414fe7 --> f22cdbe4_1771_9397_474b_361d2685b75b
  style 6643ef7b_3cd4_fdee_9d10_a5ab9a414fe7 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

import { getCollection } from 'astro:content';
import rss from '@astrojs/rss';
import { SITE_DESCRIPTION, SITE_TITLE } 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.id}/`,
		})),
	});
}

Domain

Subdomains

Functions

Dependencies

Frequently Asked Questions

What does rss.xml.js do?
rss.xml.js is a source file in the astro codebase, written in javascript. It belongs to the CoreAstro domain, RoutingSystem subdomain.
What functions are defined in rss.xml.js?
rss.xml.js defines 1 function(s): GET.
What does rss.xml.js depend on?
rss.xml.js imports 3 module(s): astro:content, consts.ts, rss.
Where is rss.xml.js in the architecture?
rss.xml.js is located at examples/blog/src/pages/rss.xml.js (domain: CoreAstro, subdomain: RoutingSystem, directory: examples/blog/src/pages).

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free