🎙 Free live masterclass · Sun, 29 Nov, 7:00 pm IST · Java Full Stack roadmap Register free →
Skills101
← Quiz: React Basics: all 10 questions

Quiz: React Basics · Question 8 of 10

What is a controlled input in React?

What is a controlled input in React?

  1. A.An input that cannot be typed in
  2. B.An input whose value comes from state and is updated through onChange
  3. C.An input with the disabled attribute
  4. D.An input validated only by the server
Answer & explanation

Correct answer: An input whose value comes from state and is updated through onChange

React state is the single source of truth for the input's value.

Can you get the rest right without peeking?

Take the timed Quiz: React Basics quiz free. Pass it to earn XP and count towards your certificate.

Start the quiz →