title: React Hook useCallback has a missing dependency warning, but the dependencies are present
body: <p>I have the following:</p>
  <pre><code>props = {
  onPositive: () =&gt; void;
  closeFunc: () =&gt; void;
  ... about 5 more props
  }
  </code></pre>
  <p>With the following hook:</p>
  <pre><code>const onPositive: () =&gt; void = useCallback(() =&gt; {
          props.positionFunc();
          props.closeFunc();
      }, [props.positionFunc, props.closeFunc]);
  </code></pre>
  <p>I am getting this warning:</p>
  <pre><code>React Hook useCallback has a missing dependency: 'props'. Either include it or remove the dependency array. However, 'props' will change when *any* prop changes, so the preferred fix is to destructure the 'props' object outside of the useCallback call and refer to those specific props inside useCallback 
  </code></pre>
  <p>From what I understand in <em>DependencyList</em> I should include the dependencies the callback has, am I missing something?</p>
  <p>I can turn-off the warning by putting <em>[props]</em> for <em>DependencyList</em> however I don't think is needed?</p>
  <p>Can somebody explain me why I should put <em>props</em> and not what I have?</p>