Closed fnep closed 1 week ago
Does this affect all operations?
Would you be able to create a minimal reproducible example on StackBlitz?
Does this affect all operations?
Not sure if I get the question right. It is an error during compile time. Actually, I assume in practice the code will work.
create a minimal reproducible example on StackBlitz
Im new to StackBlitz but i gave it a try. I hope it works for you.
-> https://stackblitz.com/edit/webpack-webpack-js-org-maeyov?file=package.json
I used
npm exec --yes @hey-api/openapi-ts@0.47.2
webpack
to get the error.
I had the same issue. I think it's related to the typescript version you use. With typescript 4 I get the same error. With typescript ^5.00 it works for me.
I'm on typescript 5.3.3 in my project, and the StackBlitz example above is on 5.5.2.
@fnep this will be fixed in the next release, but I suspect it won't solve all your issues. I tried with your example and after fixing this issue, I was getting a weird Webpack error failing to build the services.gen.ts
file if I understand it correctly. I believe this might be something to do with the Webpack config itself, but open a new issue if you find out more and think something needs to be fixed in this package.
Just updated to 0.48.0 and for me, this solved the issue entirely. Thank you! 🙂
Description
With the update from version 0.46.3 to 0.47.2, typescript is throwing an error in the generated
requests.ts
.I'm not really sure what to do with it. 😕
OpenAPI specification (optional)
No response
Configuration
System information (optional)
No response