Keats / validator

Simple validation for Rust structs
MIT License
2.03k stars 147 forks source link

Implement the same behavior as Option #241

Open affanshahid opened 1 year ago

affanshahid commented 1 year ago

I have a type which behaves the same as an Option in that it wraps another type which might or might not be there. It has some extra logic that is specific to my app. I want to give it the same behavior that an Option has i.e only validate if the value is there and pass on all validation settings to the wrapped type. How should I go about achieving this.

biot023 commented 1 year ago

+1

biot023 commented 1 year ago

(In my case it's the MaybeUndefined<T> from async_graphql InputObject.)