Howto generate code for Typescript-Angular2 with Swagger Codegen which contains validation information

852 Views Asked by At

I use swagger-codegen version 2.2.3 to generate an API for typescript-angular2 - so far everything works great.

The command I use is:

java -jar ./swagger-codegen-cli-2.2.3.jar generate -i http://example.ch/swagger/docs/v1 -l typescript-angular2 -o ./src/api -DsupportES6=true -DmodelPropertyNaming=original

The Swagger JSON file contains as well additional information. e.g. minLength, maxLength of a string, see following picture.

enter image description here

I cannot find this information (minLength,maxLength) in the generated code.

Does swagger-coden for typescript-angular2 not support this or do is miss something?

0

There are 0 best solutions below