Open ssarkisy opened 1 year ago
Encoutering the same issue using the maven plugin :
<groupId>org.openapitools</groupId>
<artifactId>openapi-generator-maven-plugin</artifactId>
<version>5.1.0</version>
Edit: We have found a workaround, once the angular generated-sources are created
1- npm install 2- npm install @types/node@18.11.19 --save-dev 3- npm run build
I am facing the same issue. (I am using the plugin version 5.2.0) It looks like everything was working last week :) :D
Bug Report Checklist
Description
We are using Docker image of openapi-generator-cli to generate TypeScript code for Angular 11.2.14. https://hub.docker.com/r/openapitools/openapi-generator-cli/tags
Till recent time everything worked fine, but with version
18.13.0
of@types/node
it basically drops the support of Angular version before 12. https://github.com/DefinitelyTyped/DefinitelyTyped/discussions/64262Here is our generation script:
We are using version
5.3.1
, but the problem is also confirmed on6.2.0
and6.4.0
Here is the part of generated package-lock.json:
And here the errors we're getting when trying to build the API code:
Just a few days ago the
@types/node
version in generatedpackage-lock.json
was"18.11.19"
and everything worked fine.If we will try to generate an API for Angular 12.2 - there are no errors.
openapi-generator version
Docker image of version 5.3.1 https://hub.docker.com/layers/openapitools/openapi-generator-cli/v5.3.1/images/sha256-fd605a2b72f40d1491b128cab58bbcd82159a5accc4dd0f01024dac36262ccfc?context=explore
OpenAPI declaration file content or url
Any OpenAPI json/yaml file with TypeScript target using ngVersion=11.2.14. The content of the API itself is irrelevant.
Generation Details
Steps to reproduce
Related issues/PRs
Suggest a fix
Use specific @types/node version for every Angular version supported.