Sort schema properties? #162
-
First of all, great project! It helped me a lot while cleaning up a large, chaotic OpenAPI spec. One thing I was wondering, is it also possible to sort components/schemas alphabetically? before components:
schemas:
UserDto:
...
PostDto:
...
RoleDto:
... after components:
schemas:
PostDto:
...
RoleDto:
...
UserDto:
... |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 9 replies
-
If I'm not mistaken, there is support for sorting the properties by alphabet, by using |
Beta Was this translation helpful? Give feedback.
hi @luchsamapparat
The --sortComponents works only on the level of the component elements, it does not sort the properties in the elements.
example:
Becomes: