Skip to content
⚠️ Beta: API may change before v1.0. Pin to ~0.x.0 to avoid breaking changes.

API Reference

Comprehensive API reference for all useFlow functions, components, and types.

Create typed flow definitions with steps, branching, and versioning.

Primary React component for rendering flows with full control over layout and behavior.

Access flow state and navigation methods from step components.

Configure default settings for all flows in your application.

Create persisters with validation, TTL, and callbacks.

Built-in stores for localStorage, sessionStorage, AsyncStorage, and memory.

Implement custom storage backends for databases, APIs, or cloud storage.

Comprehensive TypeScript types for type-safe flow development:

  • FlowDefinition - Flow configuration type
  • RuntimeFlowDefinition<TDefinition, TContext> - Returned by defineFlow()
  • UseFlowReturn<TContext> - Return type of useFlowState()
  • FlowContext - Base type for context objects
  • PersistedFlowState<TContext> - Saved state structure
  • MigrateFunction<TContext> - Migration function type
  • ResolveFunction - Branching resolver type

See the Type Safety guide for detailed type information.