问题
We are using Swagger IO CodeGen, to create Angular API Service Proxies? Currently linking Net Core 3 APIs with Angular Typescript.
https://editor.swagger.io/
public addProduct(product?: string, observe?: 'body', reportProgress?: boolean): Observable<CreatePropertyResponse>;
public addProduct(product?: string, observe?: 'response', reportProgress?: boolean): Observable<HttpResponse<CreatePropertyResponse>>;
public addProduct(product?: string, observe?: 'events', reportProgress?: boolean): Observable<HttpEvent<CreatePropertyResponse>>;
public addProduct(product?: string, observe: any = 'body', reportProgress: boolean = false ): Observable<any> {
Its currently creating 4 methods:
- Is there a way to remove reportProgress Or maybe even Observe as a paramter variable, we don't need that.
- Additionally, how to get proxy down to 1 method, instead of 4 override methods below?
Will accept javascript answer for CodeGen.
来源:https://stackoverflow.com/questions/63145112/swagger-open-api-remove-reportprogress-in-angular-typescript