title: How do I add validation to the form in my React component?
body: <p>My Contact page form is as follows,</p>
  
  <pre class="lang-jsx prettyprint-override"><code>&lt;form name="contactform" onSubmit={this.contactSubmit.bind(this)}&gt;
    &lt;div className="col-md-6"&gt;
      &lt;fieldset&gt;
        &lt;input ref="name" type="text" size="30" placeholder="Name"/&gt;
        &lt;br/&gt;
        &lt;input refs="email" type="text" size="30" placeholder="Email"/&gt;
        &lt;br/&gt;
        &lt;input refs="phone" type="text" size="30" placeholder="Phone"/&gt;
        &lt;br/&gt;
        &lt;input refs="address" type="text" size="30" placeholder="Address"/&gt;
        &lt;br/&gt;
      &lt;/fieldset&gt;
    &lt;/div&gt;
    &lt;div className="col-md-6"&gt;
      &lt;fieldset&gt;
        &lt;textarea refs="message" cols="40" rows="20"
                  className="comments" placeholder="Message"/&gt;
      &lt;/fieldset&gt;
    &lt;/div&gt;
    &lt;div className="col-md-12"&gt;
      &lt;fieldset&gt;
        &lt;button className="btn btn-lg pro" id="submit"
                value="Submit"&gt;Send Message&lt;/button&gt;
      &lt;/fieldset&gt;
    &lt;/div&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>Need to add validation for all fields. Can anyone help me to add validation in this react form?</p>