MichalLytek / class-transformer-validator

A simple plugin for class-transformer and class-validator which combines them in a nice and programmer-friendly API.
MIT License
200 stars 19 forks source link

Add support for json array #3

Closed MichalLytek closed 7 years ago

MichalLytek commented 7 years ago

Currently transformAndValidate(classType, jsonString) returns Promise<classType> even if jsonString is a JSON array string. This feature need new type definition (Promise<classType|Array<classType>>) which will require type assertion from lib consumers.

MichalLytek commented 7 years ago

Done in dd0b538.