title: this.refs vs value in react for form usage
body: <p>How would you guys do a form submission? I have no problem making a form but I saw 2 different approach. Personally I use state to bind the form value</p>
  
  <pre><code>&lt;input onChange={this.handleInputChange} value={this.state.username} type="text" name="username" /&gt;
  </code></pre>
  
  <p>to get the input value I will do this</p>
  
  <pre><code>handleInputChange = () =&gt; (
     const username = e.target.username.value;
  )
  </code></pre>
  
  <p>It worked but not sure this is a good approach, another approach is using refs.</p>
  
  <p>The good thing is no need to put onChange on every fields, in onSubmit simply do this</p>
  
  <pre><code>this.refs.username.value
  </code></pre>
  
  <p>and you have ur element like this <code>&lt;input ref="username" type="text" /&gt;</code></p>
  
  <p>But how to set the value of the username if the initial load is an ajax?</p>