New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[typescript-angular] "type": "number" references BigDecimal, which is never generated #336
Comments
The current workaround from my side was to create export type BigDecimal = number; which is quite annoying to do every time. |
So in JS/TS there are no native solutions for arbitrary-precision decimal arithmetic, but there are e. g. these libraries to achieve it:
(At least for If you don't like to include any of them or implement BigDecimal in JS/TS on swagger's side, it does not make much sense to use some sort of Are there swagger guidelines on type projections to other languages? If there is a consent how to handle this and someone points me on the right code locations I'm happy to create a PR. With the current setup and the missing |
hi @wtho, this issue has been fixed, for latest releases, mapping |
I've run into this issue myself. A generated model attempts to import Using the latest build available to me at the moment: Edit: I'm fairly new to these tools, and I've realized that this isn't as issue for the |
@HugoMario is there any difference between swagger-codegen-cli and swagger-codegen-cli-v3? I tried More specifically when I'm using |
@itbrandonsilva @AmazingTurtle |
hey @itbrandonsilva @AmazingTurtle Can you please try with 3.0.20 version |
@HugoMario I can confirm, BigDecimal is gone by now with the 3.0.20 version. Thanks for the fix |
Issue
When generating (v3.0.5) using
and the schema (swagger: 2.0) contains a field
it generates this model:
The problem is, that the file
bigDecimal.ts
is never created.If the schema contains
it renders
someOtherField: number;
The text was updated successfully, but these errors were encountered: