AstroPrerenderer Type — astro Architecture
Architecture documentation for the AstroPrerenderer type/interface in integrations.ts from the astro codebase.
Entity Profile
Dependency Diagram
graph TD dd118857_dde1_6da7_aa91_43ddbb8876cc["AstroPrerenderer"] 5a61a076_c3db_01bc_0201_03ec73ca05bb["integrations.ts"] dd118857_dde1_6da7_aa91_43ddbb8876cc -->|defined in| 5a61a076_c3db_01bc_0201_03ec73ca05bb style dd118857_dde1_6da7_aa91_43ddbb8876cc fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
packages/astro/src/types/public/integrations.ts lines 173–194
export interface AstroPrerenderer {
name: string;
/**
* Called once before prerendering starts. Use for setup like starting a preview server.
*/
setup?: () => Promise<void>;
/**
* Returns pathnames with their routes to prerender. The route is included to avoid
* needing to re-match routes later, which can be incorrect due to route priority.
*/
getStaticPaths: () => Promise<PathWithRoute[]>;
/**
* Renders a single page. Called by Astro for each path returned by getStaticPaths.
* @param request - The request to render
* @param options - Render options including routeData
*/
render: (request: Request, options: { routeData: RouteData }) => Promise<Response>;
/**
* Called after all pages are prerendered. Use for cleanup like stopping a preview server.
*/
teardown?: () => Promise<void>;
}
Source
Frequently Asked Questions
What is the AstroPrerenderer type?
AstroPrerenderer is a type/interface in the astro codebase, defined in packages/astro/src/types/public/integrations.ts.
Where is AstroPrerenderer defined?
AstroPrerenderer is defined in packages/astro/src/types/public/integrations.ts at line 173.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free