orval
orval copied to clipboard
Bug: endpoints with multiple tags get generated and exposed multiple times
When having an endpoint definition with multiple tags this endpoint wil get generated multiple times with the mode: 'tags'
(or 'tags-split'), this causes the index.ts to not compile because it gets exposed multiple times.
What perhaps would work is to use all the tags, in the order they appear in the spec, to determine the path the endpoint files should be in. E.g. an endpoint with "tags" : ["Animal", "Cat"]
should then be generated in ./animal/cat
and exposed once instead of both in ./animal
and ./cat
and exposed twice.
Additionally, with an index file at every level, one has more precise import scopes.
I'm facing the same issue, to add on this enhancement, I have some openapi paths like /organizations/{orgaId}/members
and ideally I want to have a folder structure to have queries related to organizations in src/endpoints/organizations/organizations.ts
and the related subqueries for members in src/endpoints/organizations/members/members.ts
and if we could also have a index.ts
for those would be awesome.