-
Notifications
You must be signed in to change notification settings - Fork 41
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
Implement i18n and l10n support for hints #2
Comments
Is there ETA for this? |
@nlochschmidt do you have plans to work on this? |
Yes, but I need to design the API for #3 first. |
Ok, thanks! |
Thinking of doing this with customs properties, see #48 |
I think with #155 and #167 there are enough tools for the user to do this. You can do things like this: val validation = Validation<User> { User::age { minimum(0) hint "{some id for the i18n library}" }}
val localized = validation.validate(...).errors.map { it.copy(hint = localize(it.hint) } } or val validation = Validation<User> { User::age { minimum(0) userContext I18nLibrary.someReference } }
val localized = validation.validate(...).errors.map { it.copy(hint = I18nLibrary.localize(it.userContext as I18nLibraryRef) } } |
No description provided.
The text was updated successfully, but these errors were encountered: