Skip to content
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

[Improvement] Names should be nicer #112

Open
Zydnar opened this issue Aug 3, 2021 · 3 comments
Open

[Improvement] Names should be nicer #112

Zydnar opened this issue Aug 3, 2021 · 3 comments

Comments

@Zydnar
Copy link

Zydnar commented Aug 3, 2021

image
This looks bad and it's not only about types.
image
If you work with huge government API it's hard to correct all names and there is no way to change operationId etc.

@jonkoops
Copy link
Collaborator

jonkoops commented Aug 3, 2021

@Zydnar What is the name in the schema?

@fgnass
Copy link
Contributor

fgnass commented Dec 2, 2022

@Zydnar I just had a look at the examples. I could imagine adding an option to remove package names from references, which would already help a lot. But there are also ref names which look super weird like this one:

#/components/schemas/WasteRegisterPublic.Api.ApiModels.Collections.PaginatedPage`1[[WasteRegisterPublic.Api.ApiModels.Responses.WasteRegister.WasteRecordCard.V1.KeoListItem, WasteRegisterPublic.Api, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]]

A possible approach could be to discard everything after the first non-world character and append a counter instead. So all the types that look like the one above would end up as PaginatedPage1, PaginatedPage2, etc.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants