MichalLytek / class-transformer-validator

A simple plugin for class-transformer and class-validator which combines them in a nice and programmer-friendly API.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Add support for json array

MichalLytek opened this issue · comments

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.