TanStack
API Reference

HydrationBoundaryProps

Defined in: packages/react-query/src/HydrationBoundary.tsx:16

The props accepted by HydrationBoundary.

Properties

PropertyTypeDescription
children?ReactNodeThe components to render — always rendered unconditionally, not gated on hydration. New queries are hydrated into the cache during render; for queries that already exist in the cache, only newer dehydrated data is hydrated, and that happens in an effect after commit, so children may render briefly before it lands.
options?OmitKeyof<HydrateOptions, "defaultOptions"> & objectOptional. Note: unlike hydrate, mutations cannot be set here.
queryClient?QueryClientUse this to use a custom QueryClient. Otherwise, the one from the nearest context will be used.
stateDehydratedState | null | undefinedThe state to hydrate.