docs: Update README.md.
This commit is contained in:
@@ -1,7 +1,16 @@
|
||||
# WebClientBase - Blazor Web App .NET 10
|
||||
|
||||
> **EN**: [English Documentation](docs/en/README.md)
|
||||
> **VI**: [Tài liệu Tiếng Việt](docs/vi/README.md)
|
||||
|
||||
Base frontend web application cho GoodGo Platform được xây dựng với Blazor WebAssembly + BFF Pattern.
|
||||
|
||||
## Quick Links
|
||||
|
||||
- 📖 [Architecture](docs/en/ARCHITECTURE.md) / [Kiến trúc](docs/vi/ARCHITECTURE.md)
|
||||
- 🚀 [Quick Start](docs/en/README.md#quick-start)
|
||||
- 🔧 [Configuration](docs/en/README.md#configuration)
|
||||
|
||||
## Architecture / Kiến trúc
|
||||
|
||||
```
|
||||
@@ -17,7 +26,7 @@ Base frontend web application cho GoodGo Platform được xây dựng với Bla
|
||||
│ BFF (Backend for Frontend) │
|
||||
│ WebClientBase.Server + YARP │
|
||||
│ ┌─────────────────────────────────────────────────────────────┐ │
|
||||
│ │ Routes: /api/iam/** → iam-service │ │
|
||||
│ │ Routes: /api/iam/** → iam-service │ │
|
||||
│ │ /api/merchants/** → merchant-service │ │
|
||||
│ │ /api/catalog/** → catalog-service │ │
|
||||
│ │ /api/orders/** → order-service │ │
|
||||
@@ -43,54 +52,28 @@ Base frontend web application cho GoodGo Platform được xây dựng với Bla
|
||||
| Shared | Class Library với Data Annotations |
|
||||
| Styling | CSS Variables, Dark Mode |
|
||||
|
||||
## Project Structure / Cấu trúc dự án
|
||||
|
||||
```
|
||||
web-client-base-net/
|
||||
├── WebClientBase.slnx # Solution file
|
||||
├── src/
|
||||
│ ├── WebClientBase.Client/ # Blazor WebAssembly
|
||||
│ │ ├── Layout/ # MainLayout, NavMenu
|
||||
│ │ ├── Pages/ # Razor pages
|
||||
│ │ └── wwwroot/css/ # Design System CSS
|
||||
│ ├── WebClientBase.Server/ # BFF with YARP Proxy
|
||||
│ │ ├── Program.cs # YARP configuration
|
||||
│ │ └── yarp.json # Routes configuration
|
||||
│ └── WebClientBase.Shared/ # Shared Library
|
||||
│ └── DTOs/ # Data Transfer Objects
|
||||
└── Dockerfile
|
||||
```
|
||||
|
||||
## Getting Started / Bắt đầu
|
||||
|
||||
```bash
|
||||
# Navigate to project
|
||||
cd apps/web-client-base-net
|
||||
|
||||
# Restore packages
|
||||
dotnet restore
|
||||
|
||||
# Run BFF Server (hosts Blazor client + YARP proxy)
|
||||
dotnet run --project src/WebClientBase.Server
|
||||
|
||||
# Open browser
|
||||
# http://localhost:5091
|
||||
# Open http://localhost:5091
|
||||
```
|
||||
|
||||
## BFF Routes Configuration
|
||||
## Project Structure / Cấu trúc
|
||||
|
||||
Routes được cấu hình trong `yarp.json`:
|
||||
```
|
||||
web-client-base-net/
|
||||
├── src/
|
||||
│ ├── WebClientBase.Client/ # Blazor WebAssembly
|
||||
│ ├── WebClientBase.Server/ # BFF with YARP Proxy
|
||||
│ └── WebClientBase.Shared/ # Shared DTOs
|
||||
├── docs/
|
||||
│ ├── en/ # English docs
|
||||
│ └── vi/ # Vietnamese docs
|
||||
└── Dockerfile
|
||||
```
|
||||
|
||||
| Client Route | Proxied To | Description |
|
||||
|--------------|------------|-------------|
|
||||
| `/api/iam/**` | `http://localhost:5101/` | Identity & Access Management |
|
||||
| `/api/merchants/**` | `http://localhost:5102/` | Merchant Service |
|
||||
| `/api/catalog/**` | `http://localhost:5103/` | Catalog Service |
|
||||
| `/api/orders/**` | `http://localhost:5104/` | Order Service |
|
||||
|
||||
> **Note:** Addresses có thể override qua environment variables trong production.
|
||||
|
||||
## Related Skills
|
||||
|
||||
- [API Aggregation](../../.agent/skills/api-aggregation/SKILL.md) - BFF Pattern
|
||||
- [Project Rules](../../.agent/skills/project-rules/SKILL.md)
|
||||
See detailed documentation in [docs/en/](docs/en/) or [docs/vi/](docs/vi/).
|
||||
|
||||
Reference in New Issue
Block a user