Skip to content

LiveStoreContext

LiveStoreContext<TSchema> = LiveStoreContextRunning<TSchema> | { error: unknown; stage: "error"; } | { cause: Adapter | Adapter | Adapter; stage: "shutdown"; }

Defined in: store/store-types.ts:43

Union type representing the possible states of a LiveStore context.

Used by framework integrations (React, Solid, etc.) to track Store lifecycle:

  • running: Store is active and ready for queries/commits
  • error: Store failed during boot or operation
  • shutdown: Store was intentionally shut down or interrupted

TSchema extends Adapter = LiveStoreSchema.Any

The LiveStore schema type. Defaults to LiveStoreSchema.Any.