title: React FormEvent<HTMLFormElement> form input props types
body: <p>How to make types for form inputs?</p>
  
  <pre><code>const Index = () =&gt; {
    const handleSubmit = async (e: FormEvent&lt;HTMLFormElement&gt;) =&gt; {
      e.preventDefault()
      console.log(e.currentTarget.elements.email)
    }
  
    return (
      &lt;Layout&gt;
        &lt;form onSubmit={handleSubmit}&gt;
          &lt;input name='email' type='email' autoComplete='email' required /&gt;
          &lt;input name='password' type='password' autoComplete='password' required /&gt;
          &lt;button type='submit'&gt;Login&lt;/button&gt;
        &lt;/form&gt;
      &lt;/Layout&gt;
    )
  }
  </code></pre>
  
  <p>Type error:</p>
  
  <blockquote>
    <p>Property 'email' does not exist on type 'HTMLFormControlsCollection'.</p>
  </blockquote>