React Forms


Just like in HTML, React uses forms to allow users to interact with the web page, and you add a form with React like any other element. Handling forms is about how you handle the data when it changes value or gets submitted. In HTML, form data is usually handled by the DOM. In React, form data is usually handled by the components. When the data is handled by the components, all the data is stored in the component state. You can control changes by adding event handlers in the onChange attribute:


     




      Housework won’t kill you.    
      But then again, why take the chance?    
      — Phyllis Diller on housework