Skip to content

LiveStoreContext

LiveStoreContext = LiveStoreContextRunning | { error: UnknownError | unknown; stage: "error"; } | { cause: IntentionalShutdownCause | StoreInterrupted | SyncError; stage: "shutdown"; }

Defined in: packages/@livestore/livestore/src/store/store-types.ts:42

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