diff --git a/integrations/axum/src/lib.rs b/integrations/axum/src/lib.rs index 42d69fdd01..3a888d5406 100644 --- a/integrations/axum/src/lib.rs +++ b/integrations/axum/src/lib.rs @@ -79,6 +79,13 @@ impl ResponseParts { } /// Allows you to override details of the HTTP response like the status code and add Headers/Cookies. +/// ResponseOptions is stored in your server's context if you've called `.leptos_routes` on your router. +/// ```rust +/// #[server] +/// pub async fn get_opts() -> Result<(),ServerFnError> { +/// let opts = expect_context::(); +/// Ok(()) +/// } #[derive(Debug, Clone, Default)] pub struct ResponseOptions(pub Arc>);