title: How to disable button based on state?
body: <p>In my reactjs app I have a button that is disabled/enabled based on a state value:</p>
  
  <pre><code>&lt;button disabled={this.state.modelvalue === 0 ? true : false} onClick={this.showMessage}&gt;Select&lt;/button&gt;
  </code></pre>
  
  <p>The modelvalue state is set by changing the select value:</p>
  
  <pre><code>&lt;div className="row"&gt;
        &lt;div className="col-md-6"&gt;
              &lt;select name="" id="" value={this.state.modelvalue} onChange={this.handleChangeModel}&gt;
                &lt;option value ="0"&gt;plse select value&lt;/option&gt;
                &lt;option value ="1"&gt;One&lt;/option&gt;
              &lt;/select&gt;
        &lt;/div&gt;
  &lt;/div&gt;
  
   handleChangeModel(event) {
      this.setState({modelvalue: event.target.value});
   }
  </code></pre>
  
  <p>The handleChangeModel sets the state.modelvalue but for some reason when you change from 'one' back to 'plse select value' the button does not get disabled? Even though the state.modelvalue is 0 again?</p>