A

Admin • 833.24K Points
Coach

Q. What happens if a component returns null?

  • (A) Nothing is rendered
  • (B) An error occurs
  • (C) An empty div is rendered
  • (D) The component re-renders infinitely
  • Correct Answer - Option(A)
  • Views: 23
  • Filed under category React JS
  • Hashtags:

Explanation by: Admin

Returning null from render means nothing is output to the DOM.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.