OpenAPITools / OpenAPITools/openapi-generator
[typescript-fetch] Is it possible to skip generating docstrings? (JSDoc)
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 26.8k
- Forks
- 7.7k
- PR merge metrics
- PR metrics pending
Description
Description
I am passing --global-property=apiDocs=true,modelDocs=true to the typescript-fetch generator, and I would expect it to remove docs from the generated models and api functions, but that's not happening.
openapi-generator version
7.0.1
OpenAPI declaration file content or url
{
"$schema": "./node_modules/@openapitools/openapi-generator-cli/config.schema.json",
"spaces": 2,
"generator-cli": {
"version": "7.0.1"
}
Command line used for generation
openapi-generator-cli generate \
-g typescript-fetch \
-i ../schema.yaml \
-o ./api \
--global-property=apiDocs=false,modelDocs=false
Steps to reproduce
- Run the command
- Observe the model and api files: they are full of docstrings
Related issues/PRs
I'm searching high and low, I can't find anything.
Suggest a fix/enhancement
Maybe this is expected behavior. It would be cool to be able to remove docstrings, as the files would be more human-readable. At list by this human.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the issue with openapi-generator 7.0.1 using the shown typescript-fetch command and global properties. Inspect how the generator handles apiDocs=false and modelDocs=false, then verify generated model and API files no longer contain docstrings when the flags are disabled.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100