Q. What will happen if a hook is used inside a conditional statement?
β
Correct Answer: (C)
React will throw an error
Explanation: Hooks must be called unconditionally at the top level of a function component.