How omnedia/ts-mono-repo works
This is a NestJS/Angular starter whose implemented product is session-based user authentication, with a generated API client and a small Angular shell. The principal workflow runs from the user’s auth screen through API calls to Nest auth routes, user operations, and database-backed persistence; session and CSRF handling support that workflow. The README also describes optional Redis sessions, Swagger, theme support, and view transitions. Some of those integrations are documented but their wiring is not shown in the excerpts, so those links are marked unverified or omitted.
Main entry points: auth.controller.ts Auth routes · user.service.ts User operations · app.store.ts App and theme state · auth.service.ts Session and CSRF service
Components 24
Angular application
- App shell
frontend/src/app/app.component.ts - Route configuration
frontend/src/app/app.routes.ts - Auth screen
frontend/src/app/auth/auth.component.ts - Generated API client
frontend/src/app/api/services/authentication.service.ts - API providers
frontend/src/app/api/providers.ts - Date transformer
frontend/src/app/api/utils/date-transformer.ts - HTTP params builder
frontend/src/app/api/utils/http-params-builder.ts - CSRF interceptor
frontend/src/app/interceptors/csrf.interceptor.ts - Role guard
frontend/src/app/guards/auth-role.guard.ts - Routing service
frontend/src/app/services/routing.service.ts - App and theme state
frontend/src/app/stores/app.store.ts - Theme preset
frontend/src/theme/custom.preset.ts - Router and app config
frontend/src/app/app.config.ts
NestJS API
- Backend composition
backend/src/app.module.ts - Session middleware
backend/src/middleware.module.ts
Authentication
- Auth routes
backend/src/auth/auth.controller.ts - Session and CSRF service
backend/src/auth/auth.service.ts - Local strategy
backend/src/auth/strategies/local.strategy.ts - User operations
backend/src/auth/user.service.ts - User and session types
backend/src/types/user.types.ts
Persistence and sessions
- Prisma database client
backend/src/database/prisma.service.ts - PostgreSQL
- Redis session store
Other components
- User
Connections 25
- User → Auth screen: uses
README.md - Route configuration → Auth screen: loads
frontend/src/app/app.routes.ts - App shell → Generated API client: checks current user
frontend/src/app/app.component.ts - Auth screen → Generated API client: calls auth API
frontend/src/app/auth/auth.component.ts - API providers → Date transformer: configures
frontend/src/app/api/providers.ts - Generated API client → API providers: uses
- CSRF interceptor → Session and CSRF service: sends CSRF token
- Role guard → App and theme state: checks role state
frontend/src/app/guards/auth-role.guard.ts - Routing service → App and theme state: updates navigation state
frontend/src/app/services/routing.service.ts - App shell → App and theme state: reads user and loading
frontend/src/app/app.component.ts - App and theme state → Theme preset: supports theme
- Router and app config → Theme preset: configures theme
frontend/src/app/app.config.ts - Router and app config → CSRF interceptor: registers
frontend/src/app/app.config.ts - Router and app config → Route configuration: registers routes
frontend/src/app/app.config.ts - Backend composition → Auth routes: loads module
backend/src/app.module.ts - Backend composition → Prisma database client: loads module
backend/src/app.module.ts - Auth routes → Session and CSRF service: calls
backend/src/auth/auth.controller.ts - Auth routes → User operations: calls
backend/src/auth/auth.controller.ts - Auth routes → Local strategy: guards login
- Local strategy → User operations: validates credentials
backend/src/auth/strategies/local.strategy.ts - User operations → Prisma database client: queries users
backend/src/auth/user.service.ts - User operations → PostgreSQL: persists users
README.md - Auth routes → User and session types: uses request types
backend/src/auth/auth.controller.ts - Session middleware → Session and CSRF service: configures middleware
backend/src/middleware.module.ts - Session and CSRF service → Redis session store: stores sessions
README.md