@rline/property
TypeScript icon, indicating that this package has built-in type declarations

9.7.0 • Public • Published
Logo

@rline/property

Property decorator for data transfer objects that feed data to both @nestjs/swagger and class-validator

Installation

pnpm add @rline/property

Usage

export class Abc {
  // Old way
  @ApiProperty({ type: 'string', minLength: 3, maxLength: 400 })
  @IsString()
  @IsNotEmpty()
  @MinLength(3)
  @MaxLength(400)

  // New way
  @Property({ type: 'string', required: true, minLength: 3, maxLength: 400 })
  value: string;
}

Documentation

Detailed documentation Documentation

Funding

Thank you for using @puq/core It's an open-source project, and maintaining it takes time and effort. If you find this library useful, please consider supporting its ongoing development. Your contributions help ensure that the project stays up-to-date, secure, and well-maintained.

Instant Funding

Your funding will go toward

  • Bug fixes and updates to ensure compatibility with the latest versions of dependencies.
  • New features that will make the library even more powerful.
  • Documentation improvements to help users get the most out of [Your Library Name].
  • General maintenance to keep the library running smoothly and securely.

Contact to the developer: [robert.brightline@gmail.com]

Support the developer

Readme

Keywords

Package Sidebar

Install

npm i @rline/property

Weekly Downloads

30

Version

9.7.0

License

none

Unpacked Size

11.1 kB

Total Files

14

Last publish

Collaborators

  • rbrightline