useCallback
* useCallback * -> It remembers a new reference while the re-renders -> It returns the same reference value when the depedency array values are not changed -> When depedency values changes it creates a new function reference eg: const display = useCallback(() => { console.log(count); }, [count]); count same → same function reference count changed → new function reference react compare the…
We haven't written up this one. Dev.to has the full story — the link below goes straight to it.
Source: dev.to