Chapter 10 · Example 1 · Closures in React
The stale closure bug
A memoized form whose comparison function checks only the title freezes the onClick closure, so the submitted value always logs as undefined.
Loading live editor…
Chapter 10 · Example 1 · Closures in React
A memoized form whose comparison function checks only the title freezes the onClick closure, so the submitted value always logs as undefined.