GarageUnderground is a .NET 10 Blazor WebAssembly Progressive Web App (PWA) designed to track vehicle maintenance operations by license plate.
The application will store and retrieve:
- Date of intervention
- Description and list of actions performed
- Price
- Payment status
- Vehicle license plate
The app must be simple, fast, and mobile-friendly.
The project uses:
- .NET 10
- Blazor WebAssembly
- PWA features
- LiteDB as embedded database
- .NET Aspire as orchestrator
- Deployment on Azure Container Apps
The project must adopt .NET Aspire for orchestration, developer inner-loop, system composition, and deployment consistency.
Key principles:
- Components must be modeled explicitly in Aspire
- Infrastructure, app services, and database must be declared as Aspire resources
- Aspire should handle local orchestration and future cloud deployment pipeline
Goals:
- Simplify distributed application configuration
- Ensure reproducible deployments
- Enable local orchestration of services
- Reduce configuration drift between local and production
General guidance:
- Favor simple Aspire resource definitions
- Use opinionated defaults unless overridden intentionally
- Avoid over-engineering Aspire configurations
- Container image builds must be compatible with Aspire deployment model
-
Use clean architecture and separation of concerns
-
Logical structure:
/Client /Server /Shared /Data /Models /Services /Components /Aspire
-
Keep components small, focused, and testable
-
Use dependency injection consistently
- Use LiteDB as embedded database
- Create strongly-typed collections for domain models
- Index license plate field
- Persistent local storage for offline-first support
- Avoid artificial async wrappers around LiteDB
Example:
public class MaintenanceRecord { public ObjectId Id { get; set; } public string LicensePlate { get; set; } public DateOnly Date { get; set; } public string Description { get; set; } public decimal Price { get; set; } public bool IsPaid { get; set; } }
Follow standard C# conventions. Do not use underscores "_" as prefix for private fields or methods.
Correct: private int counter;
Incorrect: private int _counter; // prohibited
Rules:
- Classes: PascalCase
- Methods: PascalCase
- Public fields: PascalCase
- Private fields: camelCase
- Parameters: camelCase
- Locals: camelCase
- No Hungarian notation
- No underscores for member names
- Prefer explicit, descriptive names
- Minimal, clean, robust
- Avoid premature abstraction
- Avoid magic values
- Write tests when feasible
- Razor components should be small and focused
- Use components to encapsulate UI logic
- Dependency injection for services
- Minimal JS interop; only when necessary
- Offline-first UX
- Persistent data
- Simple service worker
- Gradual enhancement, not complexity
- Data must survive reinstall/upgrade
- Mobile-first
- Fast and minimal UI
- Neutral aesthetic
- Dark theme optional
- Final deployment will be as containerized app in Azure Container Apps
- Aspire must be able to orchestrate containers
- Multi-stage Docker builds
- Small image footprint
Example (placeholder):
FROM mcr.microsoft.com/dotnet/sdk:10 AS build WORKDIR /src COPY . . RUN dotnet publish -c Release -o /app
FROM mcr.microsoft.com/dotnet/aspnet:10 WORKDIR /app COPY --from=build /app . ENTRYPOINT ["dotnet", "GarageUnderground.Server.dll"]
- No authentication required for MVP
- Validate input
- Prevent database corruption
- Fast startup (<= 2s mobile)
- Low memory footprint
- Local caching
- No unnecessary HTTP calls
- Create/edit/delete maintenance record
- Filter by license plate
- Search by license plate
- Simple dashboard
- (optional) Export to JSON or CSV
- Unit tests for business logic
- PDF export
- Cloud sync
- Multi-user login
- Notifications
- OCR license plates
- AI assistance
- Each service should be isolated
- Aspire resource file(s) must define:
- App front end
- API backend
- LiteDB container or mounted volume if externalized
- Environment configuration via Aspire manifests where possible
- Avoid manual environment variable sprawl
- Keep docs short and practical
- Architecture + decisions documented in /docs
- Include Aspire diagrams if useful
- Small, focused PRs
- Clear descriptions
- Breaking changes explicitly documented
The application must be:
- Stable
- Simple
- Offline-first
- Aspire-enabled
- Container-ready
- Easy to deploy on Azure
- Professional
- Clean
- Minimal