akkurate
akkurate copied to clipboard
The expressive validation library for Kotlin
This is missing, especially for enums and sealed classes. - `isInstanceOf` - `isNotInstanceOf`
**Describe the bug** I'm defining custom constraints and there seems to be no easy way to test them. In the following example, I'd like to create a `Validatable`, but without...
Linking to the API reference is not enough because all the constraints are under the same package, its a mess to explore. We should do like [Symfony](https://symfony.com/doc/current/reference/constraints.html) or [Laravel](https://laravel.com/docs/10.x/validation#available-validation-rules), and...
It could be useful to transform a value before validating it, for example: ```kotlin Validator { this.map { it.trim('.') }.isNotBlank() } ``` By "transforming" the value, the path remains the...
Hello The following library is a complete validation library but unfortunately not updated. Please check it out and use it. https://github.com/valiktor/valiktor
We could provide some conditional helpers : - `ifNotNull` - `ifInstanceOf` Instead of: ```kotlin if (prop.unwrap() != null) prop { // this: Validatable constrain { it?.someBool == true } }...
- we sould ignore all private/protected properties - we should generate accessors for internal/public properties - a property can be public in a private class, we should be careful with...