title: React Hooks : fetch data inside useEffect warning
body: <p>I am using react Hooks <code>useEffect</code> to fetch data from API in my component</p>
  <pre><code>props.getUserInfoAction() is an Action from redux dispatching user info 
  </code></pre>
  <p><strong>Example</strong></p>
  <pre><code>useEffect(() =&gt; {
          props.getUserInfoAction();
        }, []);
  </code></pre>
  <p>works great, I can get my data but i found that i have a <code>warning</code> show up in my console.</p>
  <blockquote>
  <p>React Hook useEffect has a missing dependency: 'props'. Either include
  it or remove the dependency array. However, 'props' will change when
  <em>any</em> prop changes, so the preferred fix is to destructure the 'props' object outside of the useEffect call and refer to those specific props
  inside useEffect  react-hooks/exhaustive-deps</p>
  </blockquote>
  <p>I tried to pass the <code>props</code> in the array but by doing that i get an infinite loop of API call.</p>
  <pre><code>useEffect(() =&gt; {
              props.getUserInfoAction();
            }, [props]); 
  </code></pre>