Home / Function/ GET() — astro Function Reference

GET() — astro Function Reference

Architecture documentation for the GET() function in update.ts from the astro codebase.

Entity Profile

Dependency Diagram

graph TD
  346ac24b_5ec7_5fc1_fcfb_9c94e07afa1a["GET()"]
  3d4f6e3c_113f_56a1_613a_801cd602ccf0["update.ts"]
  346ac24b_5ec7_5fc1_fcfb_9c94e07afa1a -->|defined in| 3d4f6e3c_113f_56a1_613a_801cd602ccf0
  style 346ac24b_5ec7_5fc1_fcfb_9c94e07afa1a fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

packages/integrations/node/test/fixtures/sessions/src/pages/update.ts lines 3–10

export const GET: APIRoute = async (context) => {
	const previousObject = await context.session.get("key") ?? { value: "none" };
	const previousValue = previousObject.value;
	const sessionData = { value: "expected" };
	context.session.set("key", sessionData);
	sessionData.value = "unexpected";
	return Response.json({previousValue});
};

Domain

Subdomains

Frequently Asked Questions

What does GET() do?
GET() is a function in the astro codebase, defined in packages/integrations/node/test/fixtures/sessions/src/pages/update.ts.
Where is GET() defined?
GET() is defined in packages/integrations/node/test/fixtures/sessions/src/pages/update.ts at line 3.

Analyze Your Own Codebase

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

Try Supermodel Free