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

[Feature] Configure required properties based on Kotlin null safety. #147

Open
jpuerto opened this issue Nov 17, 2023 · 0 comments
Open

Comments

@jpuerto
Copy link

jpuerto commented Nov 17, 2023

I am currently using the following to define required properties from Kotlin data classes:

data class CarView(
    @field:Schema(required = true) val label: String,
    val description: String?,
    )

It should be great if we can avoid all this boilerplate by expressing the requirement with Kotlin Null Safety. So in previous code we do not need to annotate every field.

I think it could be expressed in the function findSchema

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

1 participant