In this screenshot we can see two warnings from react-hooks/exhaustive-deps
:
-
React Hook useCallback has an unnecessary dependency: 'b'. Either exclude it or remove the dependency array.
-
React Hook useCallback received a function whose dependencies are unknown. Pass an inline function instead.
However L14 useCallback(noop, [c])
doesn't use its c
dependency nor is an inline function yet the linter has issued no warnings whatsoever. Why?