In this blog, we will create a state validation hook in react using Yup. I am also going to use ramda a functional library (if you are not using it already, do give it a try). Yup is a JavaScript schema builder for value parsing and validation.
Full article