What problem does it solve?
Modeling remote data for React applications often leads to duplicated state, inconsistent cache updates, and manual merge logic. This Skill guides the definition of @data-client schemas so API responses are normalized into a single source of truth with identity-based caching and referentially equal results.
Core Features & Use Cases
- Schema Modeling: Define Entity, EntityMixin, Collection, Union, Values, All, Invalidate, Lazy, and Scalar schemas for objects, lists, maps, and polymorphic data.
- Mutable Collections: Use Collection extenders like push, unshift, assign, remove, and move to mutate lists and maps with consistent cache updates across nested and top-level views.
- Derived Data & Joins: Build memoized Query selectors and client-side joins via Entity.schema for relational, nested, or supplementary endpoint data.
- Use Case: When building a todo app where the same Todo appears in a user-scoped list and a global list, define one Collection with matching argsKey and nestKey so mutations on either view update both with referential equality.
Quick Start
Ask the assistant to define an Entity and Collection schema for your REST resource, including pk handling and a polymorphic Union if your API returns multiple event types.