Skip to content

@epikodelabs/streamix


@epikodelabs/streamix / react/src/public-api / hydrateAtomSnapshotFromDocument

Function: hydrateAtomSnapshotFromDocument() ​

hydrateAtomSnapshotFromDocument(targets, id?, documentRoot?): void

Defined in: projects/libraries/streamix/react/src/lib/runtime.ts:512

Reads, validates, and applies the server snapshot before React hydration. The element is removed after a successful handoff so it cannot be applied twice by a later client navigation.

Parameters ​

targets ​

Record<string, Writable<unknown>>

id? ​

string = "__streamix_snapshot"

documentRoot? ​

Pick<Document, "getElementById"> | undefined = ...

Returns ​

void

Released under the MIT License.