nestjs

Solid

Use when building NestJS services. Covers module structure, providers and scopes, validation pipes, guards and interceptors, TypeORM/Prisma integration, and testing.

API & Backend 26 stars 3 forks Updated 3 weeks ago MIT

Install

View on GitHub

Quality Score: 83/100

Stars 20%
48
Recency 20%
90
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
80
License 10%
100
Description 5%
100

Skill Content

# NestJS ## Purpose Build NestJS applications where the module graph reflects the domain, validation happens at the edge, and cross-cutting concerns live in guards and interceptors rather than being copied into every controller. ## When to Use - Building or reviewing a NestJS service. - Structuring modules, providers, and their scopes. - Implementing authentication, authorization, and request validation. - Writing unit and end-to-end tests for a Nest application. ## Capabilities - Module and provider design, including dynamic modules. - Validation with `class-validator` and the global `ValidationPipe`. - Guards (authorization), interceptors (cross-cutting), filters (error mapping). - Data access with Prisma or TypeORM, correctly scoped. - Testing with the Nest testing module and Supertest. ## Inputs - The domain boundaries the modules should follow. - The authentication scheme and the authorization model. - The persistence layer. ## Outputs - Modules that encapsulate a domain and export only their public services. - A global validation pipe with whitelisting enabled. - Controllers that are thin, and services that contain the logic. ## Workflow 1. **Model the modules on the domain** — One module per bounded capability, exporting the services other modules may use. A module that exports everything is not a boundary. 2. **Enable strict validation globally** — `whitelist: true` and `forbidNonWhitelisted: true`. Without these, a client can send extra fields and your DT...

Details

Author
nimadorostkar
Repository
nimadorostkar/Claude-Skills-collection
Created
1 months ago
Last Updated
3 weeks ago
Language
Python
License
MIT

Similar Skills

Semantically similar based on skill content — not just same category

Code & Development Listed

nestjs

Opinionated house conventions for NestJS backends — module boundaries and layering, provider wiring and injection scopes, guards/interceptors/pipes/filters, DTOs and validation, domain exceptions, config, and the Nest 11 / Express 5 behaviour that compiles cleanly and fails at runtime. Use whenever the code is NestJS (`@nestjs/*` in package.json, or `@Module`/`@Injectable`/`@Controller`/`@Cron` in the file), including when the question sounds like plain TypeScript, an OOP refactor, a code review, or an ops problem — the Nest-specific answer differs from the generic one. Typical asks: scaffolding a module, adding a controller, provider, or endpoint, wiring an enhancer, a boot-time DI or circular-import failure, a response leaking entity fields despite `@Exclude()`, a cron job firing on every replica, upgrading NestJS, or reviewing a Nest diff. Not for plain Express or Fastify, Angular, frontend, SQL, or CI.

15 Updated 4 days ago
alexander-danilenko
API & Backend Listed

nestjs

NestJS TypeScript backend development with enterprise patterns, dependency injection, modular architecture, and comprehensive testing support. Use when: (1) Project has @nestjs/core in package.json or nest-cli.json exists, (2) Creating modules, controllers, services, guards, pipes, interceptors, or filters, (3) Implementing JWT authentication or role-based authorization (RBAC/ABAC), (4) Integrating TypeORM, Prisma, or MikroORM for database operations, (5) Writing unit tests with Jest or E2E tests with supertest, (6) Setting up Swagger/OpenAPI documentation, (7) Implementing CQRS, event sourcing, or microservices patterns. Auto-detects: nest-cli.json, *.module.ts, *.controller.ts, *.service.ts, *.guard.ts, @nestjs/* packages in package.json, src/modules/ directory structure. NOT for: Pure Express.js without NestJS, frontend React/Vue/Angular code, non-TypeScript Node.js projects, Fastify without NestJS wrapper.

0 Updated today
murtazatouqeer
API & Backend Listed

nestjs-patterns

NestJS best practices, module architecture, DTOs, Guards, Interceptors, and common patterns. Use when building or reviewing NestJS backend services.

2 Updated today
desilokesh1