title: How to disable button onclick in Reactjs?
body: <p>I had a condition if the two textfield are the same it will proceed, if not then the button is disabled. I know I'm doing this wrong.</p>
  
  <pre><code>onSubmit() {
          debugger
          if  (this.state.password == this.state.password2)
              alert('same');
          else 
              alert('error');
              this.disable;
  }
  </code></pre>