CtrlK
BlogDocsLog inGet started
Tessl Logo
PluginPublic

statelyai/state-management

Model, review, and refactor application state so source state stays minimal, derived state is computed instead of synchronized, impossible states are not representable, and each piece of state lives in the right place. Use this whenever the user mentions state management, reducers, stores, Redux, Zustand, React state, Vue state, Pinia, selectors, derived state, duplicated state, boolean flags, invalid states, async status, useEffect soup, forms, wizards, filters, URL state, server state, or confusing UI logic, even if they do not explicitly ask for a "state model."

Quality

87%

Does it follow best practices?

Run evals on this skill

Adds up to 20 points to the overall score

View guide
SecuritybySnyk

Passed

No findings from the security scan

Overview
Quality
Evals
Security
Files

review-checklist.mdreferences/

Review Checklist

Use this reference when the user asks for a review, refactor guidance, or diagnosis of messy state code.

Findings to look for

  • redundant state that can be derived
  • duplicated source of truth across store, component, and URL
  • impossible state combinations
  • many booleans representing one mode
  • props mirrored into local state
  • effects that synchronize state rather than react to external systems
  • selected object and selected ID both stored
  • local UI state pushed global without a clear ownership reason
  • relational data stored in shapes that make updates inconsistent
  • async lifecycle modeled as disconnected flags
  • setters exposed everywhere without event or transition boundaries

Good review output

Lead with:

  1. the invalid or risky state shapes
  2. the concrete bug or regression each shape can produce
  3. the smaller state model that removes the risk

Then map that model to the current stack.

Refactor order

When suggesting a cleanup, prefer this order:

  1. remove duplicated and derived state
  2. collapse booleans into explicit status
  3. separate server, client, URL, and ephemeral concerns
  4. move derivations into selectors/getters/computed values
  5. tighten actions and transitions

That order usually improves clarity faster than introducing a new library.

LICENSE

README.md

SKILL.md

tile.json