Reactjs – Form input validation
You should avoid using refs, you can do it with onChange function. On every change, update the state for the changed field. Then you can easily check if that field is empty or whatever else you want. You could do something as follows : In this example I did the validation only for email and name, but … Read more