What problem does it solve?
This Skill prevents broken-feeling pages by ensuring your app shows clear, actionable UI when fetched data returns zero results or fails to load.
Core Features & Use Cases
- Finds data-fetch entry points: Traces
useQuery / useSuspenseQuery, route loaders, and loader/fetcher consumption sites to determine where empty and error UI must live.
- Validates the three required branches: Confirms Loading (out of scope for this skill), plus correct Empty and Error handling for each fetch surface.
- Reuses existing UI primitives: Preferentially uses the project’s existing
<EmptyState /> (or equivalent) and proposes the smallest consistent component only if nothing matches.
- Applies safe, user-friendly error messaging: Ensures errors show a human-readable message and includes retry affordance, surfacing raw error details only in dev.
Quick Start
Tell the AI: “Add empty and error states for the route/component I just wired with useQuery or a TanStack loader, using the project’s existing EmptyState/ErrorState patterns.”