πŸ“Š React Js
Q. What will happen if you change the state directly without setState or useState?
  • (A) The component will update
  • (B) The component will not re-render
  • (C) An error will occur
  • (D) React will auto-detect changes
πŸ’¬ Discuss
βœ… Correct Answer: (B) The component will not re-render

Explanation: React will not re-render if state is mutated directly without using setState or the setter function from useState.

Explanation by: Mr. Dubey
React will not re-render if state is mutated directly without using setState or the setter function from useState.

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
87
Total Visits
πŸ“½οΈ
11 mo ago
Published
πŸŽ–οΈ
Mr. Dubey
Publisher
πŸ“ˆ
85%
Success Rate