Design-first XState v5 skill that picks between xstate and @xstate/store and writes modern TypeScript machines.

CCM score
63 of 100
skills.sh installs
541
GitHub stars
50
last updated
Aug 21, 2026
View on GitHub

Own this skill? Claim it

What it does

  • Covers machine and statechart design, implementation, review, and v4-to-v5 migration, with minimal-change rules for existing code
  • Includes guidance on choosing @xstate/store for simple event state, actor kinds (fromPromise, fromCallback), and typed setup(...) patterns
  • Enforces v5-only output, TypeScript-first examples, and avoidance of loose casts such as as any in final code
  • Designed for teams building non-trivial UI, workflow, or process logic in codebases that already use XState

Install

$ npx -y skills add statelyai/skills --skill xstate-v5 -y

Installs into .agents/skills for every agent it finds here, and .claude/skills for Claude Code.

Files

XState v5

Use this skill for state machine and statechart engineering first and API correctness second.

This skill is v5-only. When examples, blog posts, answers, or local code smell v4-ish, translate them rather than mixing versions. Prefer local repo code and official v5 docs over generic memory.

Your job:

  • choose between xstate and @xstate/store
  • design a sound machine or actor system from messy requirements
  • write modern XState v5 TypeScript code in a consistent style
  • review, repair, or improve existing XState code
  • migrate legacy v4-ish patterns when they appear
  • choose the right actor kind and action shape when the problem is not just assign(...) plus fromPromise(...)
  • connect machines and actors to @xstate/react, @xstate/vue, @xstate/svelte, or @xstate/solid when needed

First pass

In an existing codebase:

  1. Inspect local package.json files and imports.
  2. Read nearby machines, stores, actors, and adapter usage.
  3. Distinguish between new code, local edits, and migration work before choosing how opinionated to be.
  4. Preserve surrounding style by default.

Task mode

Choose a mode before writing code:

Details

Repository
github.com/statelyai/skills
Categories
Frontend & UI Code, Code Review & Quality
First seen
Jun 3, 2026

Similar to Xstate V5

More Frontend & UI Code