title: Changing the value of input field - React
body: <p>I've been trying to change the value of input field after I select the item from <strong>SelectField from MaterialUI library</strong> but I haven't succeed it yet but as far as I did search on it, everything that I wrote seems like what it is supposed to be. </p>
  
  <p>This is what I use to change the value;</p>
  
  <pre><code>    var element = ReactDOM.findDOMNode(this.refs._deviceId);
      element.setAttribute('value', 'deneme');
      console.log(element);
  </code></pre>
  
  <p>This is the input field;</p>
  
  <pre><code>              &lt;div className="form-group row"&gt;
                  &lt;label className="col-md-2 control-label"&gt;Device ID&lt;/label&gt;
                  &lt;div className="col-md-10"&gt;
                    &lt;input type="text" className="form-control" id="deviceId" placeholder="Device ID" ref="_deviceId" /&gt;
                  &lt;/div&gt;
                &lt;/div&gt;
  </code></pre>
  
  <p>And I consoled the <strong>element variable</strong> after I select the item, in order to check everything is okay and it seems there is no problem.</p>
  
  <p>Here is the console log;</p>
  
  <p><a href="https://i.stack.imgur.com/RC3nC.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/RC3nC.jpg" alt="enter image description here"></a></p>
  
  <p>As you see, the value is placed successfully but on the screen, nothing happens to input field.</p>