Comments (8)
It totally makes sense to me.
from swagger-codegen-generators.
@reta Hi! Yup, that makes perfect sense. Of course it would mean using all 2.x annotations and not just @Schema
but the idea itself is right.
from swagger-codegen-generators.
Thank you guys, on it.
from swagger-codegen-generators.
@webron @HugoMario I started the work on this issue, the scope is larger then I initially expected, I opened #101 (work-in-progress) so you guys could see the progress and guide me through.
As I have got to know the code a bit more, my understanding is that Swagger Codegen Generators
module deals with OAS 3.0.x specification only (not the old 2.x one), so I made the changes non-conditional and always use OAS 3.0.x annotations for code generation. Please correct me if I am wrong here.
from swagger-codegen-generators.
Hello @reta , sorry for delay answer, i wasn't around these last days.
I think your approach is correct and PR LGTM, but i think we need to add an option that let users keep on using the previous annotation. I can help with that.
So the idea is having by default the OAS 3 annotation but leaving an option to anybody that want to keep using the previous one. Let me know if you are done with changes here and i'll file a new ticket for that.
Thanks!
from swagger-codegen-generators.
Hey @HugoMario,
Thanks for looking! Yeah, it would be a bit of work / conditionals, but makes sense overall, will be working on updating the PR to have both specs supported.
Thanks!
from swagger-codegen-generators.
Hey @reta
It sounds great, also if you check this guide https://github.com/swagger-api/swagger-codegen/wiki/How-to-add-an-option-to-a-specific-language-or-framework it would give you an idea. I think it can help us with this feature.
from swagger-codegen-generators.
this has been implemented, so let's close it
from swagger-codegen-generators.
Related Issues (20)
- OneOf property is failing during OAS Schema Validation
- Java-XML-Binding is only for javax and jakarta is ignored HOT 1
- Options have String values that are `boolean-type`
- [ASPNETCORE] bad character in generated file HOT 1
- [AspNetCore] The models inheritance is not enforced in Equals
- [typescript-angular] isFileResponse cannot be used HOT 2
- CVE-2019-015052 & CVE-2016-6199
- Operation info: The generated information does not match the expectations. HOT 1
- Python asyncio client inconsistent
- Fix ES5 Javascript Templates HOT 2
- Javascript output code can not be run because `static` keyword
- [python-flask] invalid content of a generated `__init__.py` file
- [python-flask] the operationId is not incorrectly sanitized
- Where is 1.0.48 release?
- [JavaSpring] Missing @Valid annotation for multipard/form-data content type if part is object
- Extra generated regex pattern delimiters ('/') generates code that does not work for kotlin
- Breaking change introduced by #1259
- `@NotNull` is added by default for fields that are not required
- Generator fails on null enum choice
- [typescript] Incorrect `extends null<...>` declaration for map/dictionary-like schema definitions with `additionalProperties` HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from swagger-codegen-generators.