title: React hooks exhaustive-deps rule also requires functions in useEffect array
body: <p>so I've got following effect</p>
  
  <pre><code>  useEffect(() =&gt; {
      if (disabled) {
        setAnimatedValue(0);
      } else {
        setAnimatedValue(1);
      }
    }, [disabled]);
  </code></pre>
  
  <p>That simply animates button to its enabled or disabled state if <code>disabled</code> prop changes.</p>
  
  <p>I also added following rule to my eslint config</p>
  
  <pre><code>  'react-hooks/exhaustive-deps': 'warn',
  </code></pre>
  
  <p>Now I'm getting a warning that <code>setAnimatedValue</code> needs to be added to my <code>useEffect</code> array alongside <code>disabled</code> prop, but it is just a function that's neither a state nor a prop, so it shouldn't really go in there as far as I understand.</p>
  
  <p>Is there a way to somehow make this rule only warn if I am missing <code>state</code> or <code>prop</code> value?</p>