Essential session storage is required to sign in. Optional analytics remain off unless you allow them.
Build an app that talks to a real API using a server-state library (React Query/SWR): queries with caching and loading/error states, mutations with cache invalidation so the UI stays in sync, at least one reusable custom hook, and effects used ONLY to synchronize with external systems (with cleanup). Typed end to end with TypeScript.
Query library used for API data (caching, loading/error); mutations invalidate queries to keep the UI in sync.
useEffect only for external synchronization, with cleanup; no effects deriving state from state.
At least one well-factored custom hook; Rules of Hooks respected; logic reused, not duplicated.
Props/state/API responses typed; data flow is type-checked end to end.
Use this README structure to make the work reviewable.
DevPath fetches a read-only, size-capped snapshot. Submitted code is never executed.
# Data-driven app with a server-state library and custom hooks ## Goal Build an app that talks to a real API using a server-state library (React Query/SWR): queries with caching and loading/error states, mutations with cache invalidation so the UI stays in sync, at least one reusable custom hook, and effects used ONLY to synchronize with external systems (with cleanup). Typed end to end with TypeScript. ## Acceptance criteria - [ ] Server state: Query library used for API data (caching, loading/error); mutations invalidate queries to keep the UI in sync. - [ ] Effects discipline: useEffect only for external synchronization, with cleanup; no effects deriving state from state. - [ ] Custom hooks: At least one well-factored custom hook; Rules of Hooks respected; logic reused, not duplicated. - [ ] Types: Props/state/API responses typed; data flow is type-checked end to end. ## Verification - [ ] Document installation and run commands. - [ ] Record automated checks and their exact commands. - [ ] Add representative output, screenshots, or a short demo where useful. - [ ] Confirm failure paths and known constraints. ## Decision log ### Decision title - Context: - Choice: - Alternatives considered: - Tradeoffs: ## Evidence - Link each rubric criterion to the file, test, or artifact that demonstrates it. ## Known limitations - List what is intentionally out of scope and what should be improved next.