📜  类验证器枚举 - TypeScript 代码示例

📅  最后修改于: 2022-03-11 14:48:27.629000             🧑  作者: Mango

代码示例2
export class UserDto {
  @IsEmail()
  readonly email: string;

  @IsOptional()
  @IsEnum(Permissions, { each: true })
  readonly permissions: Permissions[]; <- How to validate this?
}