add cursor
This commit is contained in:
12
.cursor/rules/nestjs-module-structure-guidelines.mdc
Normal file
12
.cursor/rules/nestjs-module-structure-guidelines.mdc
Normal file
@@ -0,0 +1,12 @@
|
||||
---
|
||||
description: Prescribes the structure and components within NestJS modules, including controllers, models, DTOs, and services, ensuring API encapsulation.
|
||||
globs: src/modules/**/*.*
|
||||
---
|
||||
- One module per main domain/route.
|
||||
- One controller for its route.
|
||||
- And other controllers for secondary routes.
|
||||
- A models folder with data types.
|
||||
- DTOs validated with class-validator for inputs.
|
||||
- Declare simple types for outputs.
|
||||
- A services module with business logic and persistence.
|
||||
- One service per entity.
|
||||
Reference in New Issue
Block a user