How to use the class-validator.Validator function in class-validator

To help you get started, we’ve selected a few class-validator examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github nest-cloud / nestcloud / packages / validations / MinLength.ts View on Github external
constructor(min: number, message?: string) {
        this.message = message || '';
        this.validator = new Validator();
        this.min = min;
    }
github nest-cloud / nestcloud / packages / validations / IsJSON.ts View on Github external
constructor(message?: string) {
        this.message = message || '';
        this.validator = new Validator();
    }
github nest-cloud / nestcloud / packages / validations / IsNotIn.ts View on Github external
constructor(possibleValues: any[], message?: string) {
        this.message = message || '';
        this.possibleValues = possibleValues;
        this.validator = new Validator();
    }
github nest-cloud / nestcloud / packages / validations / Min.ts View on Github external
constructor(min: number, message?: string) {
        this.message = message || '';
        this.validator = new Validator();
        this.min = min;
    }
github nest-cloud / nestcloud / packages / validations / IsUUID.ts View on Github external
constructor(message?: string) {
        this.message = message || '';
        this.validator = new Validator();
    }
github nest-cloud / nestcloud / packages / validations / IsIP.ts View on Github external
constructor(message?: string) {
        this.message = message || '';
        this.validator = new Validator();
    }
github nest-cloud / nestcloud / packages / validations / MaxLength.ts View on Github external
constructor(max: number, message?: string) {
        this.message = message || '';
        this.validator = new Validator();
        this.max = max;
    }
github kuangshp / nestjs-mysql-api / src / core / user / user.service.ts View on Github external
constructor(
    @InjectRepository(UserEntity)
    private readonly userRepository: Repository,
  ) {
    this.nodeAuth = new NodeAuth(8, 10, true);
    this.validator = new Validator();
  }
github nest-cloud / nestcloud / packages / validations / IsNumber.ts View on Github external
constructor(message?: string) {
        this.message = message || '';
        this.validator = new Validator();
    }
github nest-cloud / nestcloud / packages / validations / IsDefined.ts View on Github external
constructor(message?: string) {
        this.message = message || '';
        this.validator = new Validator();
    }