Replies: 2 comments 10 replies
-
@AllieJonsson i don't think this is currently supported. Enum's to me should map exactly as they are in OpenAPI. |
Beta Was this translation helpful? Give feedback.
7 replies
-
I would like to have this config option as well! |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi!
Is there a way to somehow modify generated enum keys except doing it in openapi schema?
I want to convert enum keys from snake_case to camelCase. Original enum values are snake_case, so I need to convert only keys.
I have an openapi v3 schema, it looks like this:
And generated enum looks like this:
I see that I can set enum names manually orval docs in openapi file, but openapi file is generated too, so editing it is not an option.
It looks like getEnumNames doesn't support any enum keys modification configs, but maybe there is a workaround for this?.. 🤔
Btw I'm struggling to configure a flow to convert
snake_case
'd openapi source file tocamelCase
'd generated files, and it feels like pain. I use openapi-format as a workaround to change casings, but it still feels so complicated to work with it.Maybe there are some easier ways to convert casings in orval?...
Beta Was this translation helpful? Give feedback.
All reactions