ddd-reactlisted
Install: claude install-skill salimramirez/agent-skills
# DDD in React
Structure a **React** app around a domain. Start with the honest part below — DDD on the frontend is *adapted*, not the same as on the backend — then apply the structure and the idioms in the references.
This is an **opinionated** house style: for every decision it names one convention and says what that convention buys, rather than listing options. It is one coherent way to do this, not the only correct one; where a choice is genuinely open, the reference says so. Examples use the **QuickBite** food-delivery domain, in an `ordering` bounded context.
The stack is **React with TypeScript, React Router, Zustand and axios**, built with Vite, for a client-rendered SPA. `javascript.md` covers what changes if your project is JavaScript.
> **Where this comes from.** Its siblings `ddd-angular` and `ddd-vue` mirror real codebases. This one does not: it **derives** the same four-layer model onto React, and every framework-specific claim in it was checked by building and running a real app rather than by reasoning. Where React genuinely differs, the reference says what was measured. Treat the DDD structure as settled and the React mechanics as a well-tested opinion.
## What DDD means on the frontend
The backend is the **system of record**: it owns the business rules, the invariants, and the transactional consistency. The frontend cannot enforce those — a determined user can bypass any client-side check — so it should not pretend to.
What the frontend *does* gain fr