-
Notifications
You must be signed in to change notification settings - Fork 1
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
OpenAPI: Add discriminators #80
Conversation
@@ -59,6 +59,7 @@ func CompilerPasses() []compiler.Pass { | |||
return []compiler.Pass{ | |||
&compiler.Unspec{}, | |||
&compiler.DashboardPanelsRewrite{}, | |||
&compiler.PrefixEnumValues{}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we need that for typescript? 🤔
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because I saw the same problem with the integer enums and they are setting number as names and they are invalid.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Then I think we should probably have a different compiler pass, specifically for that use-case :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This one is working as expected... what is the difference?
Relates: #58
It adds discriminators for
oneOf
andanyOf
for OpenAPI.allOf
will be in other PR since it needs refactor of references to be able to point to external files.