A

Admin • 833.24K Points
Coach

Q. What will happen if you modify state directly in React?

  • (A) Component re-renders correctly
  • (B) State change is ignored
  • (C) React throws an error
  • (D) Component may behave unexpectedly
  • Correct Answer - Option(D)
  • Views: 25
  • Filed under category React JS
  • Hashtags:

Explanation by: Admin

Direct state mutation can lead to bugs and unpredictable behavior.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.