Skip to Content
Reference

TanStack Start

Server sessions and hydration for TanStack Start.

import { … } from "@monarcode/session-kit/tanstack-start";

Guide: TanStack Start.

Functions

loadSession

Reads this request's session into the client. Call it in the root route's beforeLoad.

sessionHydration

Router options that carry the session from the server render to the browser. Spread them into createRouter.

Types

DehydratedSession

The session the server render sends to the browser, from sessionHydration's dehydrate. It holds no tokens.

SessionHydration

The router options sessionHydration returns, for createRouter.

On this page