Update README.md

This commit is contained in:
2026-08-03 08:27:25 +00:00
parent fc7e2b7c2a
commit d55a006a40

View File

@@ -1,55 +1,80 @@
# React-Dotnet Frewaork Sekelon # React-Dotnet Framework Sekelon
Once upon a time, people maintained "skeleton" repos they could clone to quickly jumpstart new projects. Why? It was quick, free and it worked.
Once upon a time, people maintinaed "skeleton" repos they could clone to quickly jumpstart new projects. Why? It was quick, free and it worked.
# A.B.C. # A.B.C.
A. Always B. Be. Cognitively TokenWoxxxening
A. Always
B. Be.
C. Cognitively TokenWoxxxening
### This is a full-stask project jumpstarter with: ### This is a full-stask project jumpstarter with:
### .NET backend ### .NET backend
### React/Vite frontend ### React/Vite frontend
# .Net
Five CRUD endpoints return correct status codes:
201 with a proper Location header # .Net
400 on invalid email, 409 on duplicate, 204 then 404 on delete), 150 requests to /v1/info yielded exactly 100 successes and the rest 429, and 40 requests to /health all returned 200 while that window was exhausted.
Five CRUD endpoints return correct status codes:
201 with a proper Location header
400 on invalid email, 409 on duplicate, 204 then 404 on delete), 150 requests to /v1/info yielded exactly 100 successes and the rest 429, and 40 requests to /health all returned 200 while that window was exhausted.
## Prerequisites ## Prerequisites
- [.NET SDK](https://dotnet.microsoft.com/download) (project targets `net10.0`) - [.NET SDK](https://dotnet.microsoft.com/download) (project targets `net10.0`)
- [Node.js](https://nodejs.org/) (LTS recommended) - [Node.js](https://nodejs.org/) (LTS recommended)
## Backend ## Backend
From the repository root: From the repository root:
```bash ```bash
cd backend cd backend
dotnet run dotnet run
``` ```
The API runs at `http://localhost:5231`. Swagger UI is available in Development at `http://localhost:5231/swagger`. The API runs at `http://localhost:5231`. Swagger UI is available in Development at `http://localhost:5231/swagger`.
Skeleton endpoints: Skeleton endpoints:
- `GET /health` — liveness check, exempt from rate limiting - `GET /health` — liveness check, exempt from rate limiting
- `GET /v1/info` — app name, version, environment, and server timestamp - `GET /v1/info` — app name, version, environment, and server timestamp
- `GET|POST /v1/users`, `GET|PUT|DELETE /v1/users/{id}` — placeholder CRUD over the - `GET|POST /v1/users`, `GET|PUT|DELETE /v1/users/{id}` — placeholder CRUD over the
in-memory repository in-memory repository
Requests are rate limited per client IP using the `RateLimiting` section of Requests are rate limited per client IP using the `RateLimiting` section of
`appsettings.json`, and allowed CORS origins come from the `Cors` section. Storage is `appsettings.json`, and allowed CORS origins come from the `Cors` section. Storage is
selected by `Persistence:Provider`, which currently supports `InMemory` only; data is selected by `Persistence:Provider`, which currently supports `InMemory` only; data is
lost on restart until a real provider is registered in lost on restart until a real provider is registered in
`backend/Data/PersistenceServiceCollectionExtensions.cs`. `backend/Data/PersistenceServiceCollectionExtensions.cs`.
## Frontend ## Frontend
From the repository root: From the repository root:
```bash ```bash
cd frontend cd frontend
npm install npm install
@@ -66,11 +91,16 @@ VITE_API_BASE_URL=http://localhost:5231
## Running both ## Running both
Start the backend and frontend in separate terminals. The backend CORS policy allows requests from `http://localhost:3000` by default; change `Cors:AllowedOrigins` in `backend/appsettings.json` to add more. Start the backend and frontend in separate terminals. The backend CORS policy allows requests from `http://localhost:3000` by default; change `Cors:AllowedOrigins` in `backend/appsettings.json` to add more.
## Project structure ## Project structure
``` ```
backend/ ASP.NET Core Web API backend/ ASP.NET Core Web API
frontend/ React + Vite + TypeScript SPA frontend/ React + Vite + TypeScript SPA
``` ```