From 01feed47036b1f628ecc96cbe5bfd9f4c8987765 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20=C5=A0vr=C4=8Dina?= Date: Tue, 17 Mar 2026 00:43:24 +0100 Subject: [PATCH] Update CLAUDE.md to reflect current project state - Add NSwag client generation details and usage convention - Add TypeScript, Pinia, Axios to frontend stack - Change project structure from 'planned' to actual - Document BaseModel and AppDbContext conventions - Mark JWT/FluentValidation as planned (not yet implemented) Co-Authored-By: Claude Sonnet 4.6 --- CLAUDE.md | 34 +++++++++++++++++++++++++--------- 1 file changed, 25 insertions(+), 9 deletions(-) diff --git a/CLAUDE.md b/CLAUDE.md index cd3fcde..965fe37 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -4,33 +4,49 @@ A Facebook Events replacement webapp for a private friend group. ## Stack -- **Backend:** .NET 8 Web API, Clean Architecture, EF Core 8, FluentValidation, JWT auth +- **Backend:** .NET 8 Web API, Clean Architecture, EF Core 8 + Pomelo.EntityFrameworkCore.MySql, NSwag, JWT auth (planned) - **Database:** MySQL -- **Frontend:** Vue 3 (Vite), Vuetify 3 +- **Frontend:** Vue 3 (Vite), Vuetify 3, TypeScript, Pinia, Axios +- **API client:** Auto-generated TypeScript client via NSwag on every backend build - **Version control:** Gitea at https://git.svrcina.eu/martin/claude-test.git -## Project Structure (planned) +## Project Structure ``` claude-test/ +├── ClaudeTest.sln ├── backend/ -│ ├── ClaudeTest.API/ # Controllers, middleware, DI config -│ ├── ClaudeTest.Application/ # Services, DTOs, validators -│ ├── ClaudeTest.Domain/ # Entities, domain interfaces -│ └── ClaudeTest.Infrastructure/# EF Core, repositories, email -├── frontend/ # Vue 3 + Vuetify 3 app -└── CLAUDE.md +│ ├── ClaudeTest.API/ # Controllers, middleware, DI config, nswag.json +│ ├── ClaudeTest.Application/ # Services, DTOs, validators (FluentValidation) +│ ├── ClaudeTest.Domain/ # Entities, domain interfaces +│ │ └── Common/BaseModel.cs # Base entity: Id, Created, Updated, Deleted +│ └── ClaudeTest.Infrastructure/ # EF Core, AppDbContext, repositories +│ └── Persistence/AppDbContext.cs +└── frontend/ # Vue 3 + Vuetify 3 app + └── src/api/apiClient.ts # Auto-generated by NSwag (gitignored) ``` ## Conventions - REST API with consistent JSON responses and HTTP status codes - EF Core code-first migrations (never edit migrations manually) +- All entities inherit from `BaseModel` (Id, Created, Updated, Deleted) +- `AppDbContext` sets `Created`/`Updated` automatically via `ChangeTracker` +- All timestamps stored as UTC (`DateTime.UtcNow`) - DTOs for all API input/output (never expose domain entities directly) - FluentValidation for all request validation - Async/await throughout the backend - Vue 3 Composition API (`