RicoSuter / NSwag

The Swagger/OpenAPI toolchain for .NET, ASP.NET Core and TypeScript.
http://NSwag.org
MIT License
6.67k stars 1.23k forks source link

Nswag 14: Url generation replace for parameters is now append #4740

Closed tommyka closed 6 months ago

tommyka commented 6 months ago

Endpoints with parameters in the URL are not working in nswag 14.

In the client generated for v 13.2 the code was as following image

but in v 14.0.2 its image

now the url still includes the {url} in the text, and the endpoints don't match up.

RicoSuter commented 6 months ago

@paulomorgado could this be a regression of the optimization? Can you have a look?

RicoSuter commented 6 months ago

Seems to be a regression of https://github.com/RicoSuter/NSwag/pull/4579

tommyka commented 6 months ago

Vi found it was related to using a custom class template that that was created from the v13 templates.

Vi have used the v14 template and migrated our changes over, and its now fixed.

RicoSuter commented 6 months ago

https://github.com/RicoSuter/NSwag/pull/4755

RicoSuter commented 6 months ago

hmm...

RicoSuter commented 6 months ago

Ok can we close the issue then?