Instructions
- •Preparation:
- •Review
Docs/Technical/for relevant guidelines. - •Check
Docs/Reference/Glossary.mdfor consistent naming. - •Check
Docs/Reference/DataModel.mdfor the database schema.
- •Review
- •TDD First:
- •Start by writing failing tests in
DerotMyBrain.Tests(Backend) orsrc/frontend/src/**/*.test.tsx(Frontend). - •Ensure tests cover nominal, edge, and error cases.
- •Start by writing failing tests in
- •Backend Implementation:
- •Follow Clean Architecture: Core -> Infrastructure -> API.
- •Use
PascalCasefor methods,_camelCasefor fields. - •Ensure thin controllers and thick services.
- •Frontend Implementation:
- •Follow layered architecture: API -> (Store) -> Hook -> Component.
- •Use semantic Tailwind classes (e.g.,
bg-background). - •Move all logic to Custom Hooks.
- •Data Persistence:
- •Use SQLite + EF Core. No external DBs.
- •Seed realistic data for
TestUser.
- •Review:
- •Run all tests:
dotnet testandnpm test. - •Check for lint errors or hardcoded colors.
- •Run all tests:
Critical Constraints
- •NO direct API calls in Components.
- •NO business logic in Controllers.
- •TDD is mandatory.
- •Mock data for
TestUseris mandatory.