79114752

Date: 2024-10-22 15:15:38
Score: 1.5
Natty:
Report link
  1. onClick={() => setState(!currentState)}

  2. onClick={() => setState((prev) => !prev)}

here is the functional component version

Reasons:
  • Low length (1):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: Omar