0.1.0 • Published 11 months ago

@getlarge/nestjs-tools-eslint-rules v0.1.0

Weekly downloads
-
License
Apache-2.0
Repository
-
Last release
11 months ago

eslint-rules

npm

This set of ESLint rules is provided to enforce a consistent patterns and practices across all NestJS projects.

Installation

npm install --save @getlarge/nestjs-tools-eslint-rules

Usage

return-class-instance

This rule enforces that all public Service methods return a class instance of the same return type. The purpose of this rule is to ensure you return class instances instead of plain objects, which is essentials when using the ClassSerializerInterceptor.

{
  "rules": {
    "@getlarge/nestjs-tools-eslint-rules/return-class-instance": "error"
  }
}
0.1.0

11 months ago