0
Challenge · 66Architecture & State
React Hook Form
Ecoused in ~75% of apps
A form with ten controlled inputs re-renders the whole form on every keystroke. React Hook Form keeps inputs uncontrolled, so typing barely re-renders anything — and gives you register + handleSubmit + a tidy errors object for free. It is the de-facto React form library in 2026.
Core idea. useForm() hands you register (wire an input to the form by spreading {...register("name", rules)}), handleSubmit (validate, then call your onValid with the collected values), and formState.errors — all built on uncontrolled inputs so React re-renders only when validation state changes, not on every key.
poke it, drag it,
try to break it
try to break it
no slides here.
you drive.
you drive.
Playground, this isn't a screenshot
Same form, two engines — watch the render counters
Type a few characters into each form, then blur or submit. The counters tell the story.
0
useState renders
0
RHF renders
The register-ed inputs are uncontrolled — React Hook Form holds values in the DOM via a ref and only re-renders when validation state actually changes. The useState form re-renders on every single keystroke.
↑ play a little first, then dig in