79626796

Date: 2025-05-17 17:11:25
Score: 1.5
Natty:
Report link

In my case React rendered 0 when children was empty.

Using children && didn't help:

{children && <div> {children} </div>}

But !!children worked:

{!!children && <div> {children} </div>}

https://www.codemzy.com/blog/react-render-0-conditional

Reasons:
  • Probably link only (1):
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (0.5):
Posted by: Shub