Swagger-codegen: Update Typescript-Angular (as of 2.3.0) To use Angular 4.3 HTTPClient optionally

Created on 16 Jul 2017  路  2Comments  路  Source: swagger-api/swagger-codegen

Description

VIA https://angular.io/guide/http

As of Angular 4.3 they have decided to create a new API for the HTTP client. As such we should update the generated Typescript-Angular client to use the new API as the old API will be deprecated in the future. I foresee people no updating their Angular version strictly for their swagger generated code so that's why I think this should optional post 2.3.0 and not required.

The enhancement idea would be to either follow the 2.3.0 ngVersion flag and select 4.3 for the newly HTTP or to have another flag that signifies you want to use it. I'd suggest sticking to the ngVersion way due to changes in dependencies needing to be made as well.

This issue was mostly made for tracking purposes so we don't forget.

TypeScript General

Most helpful comment

Is somebody already working on this?

All 2 comments

Is somebody already working on this?

I have started implementing this, and it works fine for header, query and body parameters, but I have yet to find a way to pass form parameters, and I am not sure how to pass multiple values to header and query params.

If anybody knows how that works, some hints would be appreciated.

Was this page helpful?
0 / 5 - 0 ratings