title: How do you conditionally disable a form input in react?
body: <p>I would like to disable the validated input if an item meets a certain criteria. In this case if a product has a promotion. </p>
  
  <p>Ideally I would like to do something like this: </p>
  
  <pre><code>&lt;ValidatedInput
    className='product-dropdown'
    onChange={this.onProductChange.bind(this)}
    defaultValue={example.product_id}
    componentClass='select'
    name='product_id'
    placeholder='select'
    disabled={isDisabledInput}
   &gt;
  
  isDisabledInput {
    if(example.has_a_promotion) {
       return true
    }
  }
  </code></pre>
  
  <p>I am using react-bootstrap-validation. </p>