Types
TypeScript type definitions for userTourKit — tour, step, and configuration interfaces that power fully type-safe onboarding flows.
userTourKit ships full TypeScript definitions for every primitive in the library, so your editor can autocomplete tour configuration and catch mismatches at build time. The types live in @tour-kit/core and are re-exported from @tour-kit/react, so you only need one import path regardless of which package you consume.
Types are grouped into three clusters that map to the library's runtime structure:
- Tour Types — the top-level
TourConfig, theTourStateunion describing where a tour is in its lifecycle, and the action + callback signatures you use when wiring a custom controller. - Step Types — per-step schemas including target selectors, content renderers, placement options, and the lifecycle hooks that fire on
onEnter,onLeave, andonSkip. - Config Types — provider-level configuration:
TourProviderProps, storage adapters, locale overrides, and theRouterAdapterinterface used by the Next.js and React Router integrations.
Every exported type is stable across minor releases and follows semver; breaking renames are always flagged in the changelog. If you need a type that isn't surfaced here (for example, an internal payload shape), open an issue — if it's safe to expose we'll export it in the next minor.