title: useSelector from 'react-redux' is undefined when running application
body: <p>The <code>useSelector</code> function from <code>'react-redux'</code> is <code>undefined</code> in my react application, even though the versions are up to date, and there are no errors in VS Code (I can even ctrl-click in and see the typings, and the code in the <code>node_modules</code> folder). This manifests in a few ways:</p>
  
  <p>1) The following error <code>[HMR] bundle has 1 warnings: export 'useSelector' was not found in 'react-redux'</code>. </p>
  
  <p>2) In the following component:</p>
  
  <pre><code>import React, { useState } from 'react';
  import { useSelector } from 'react-redux';  // importing useSelector does not error in VS Code
  
  const TestComponent = () =&gt; {
      const [x, setX] = useState("hello");  // useState works correctly
      console.log(useSelector);  // but useSelector is undefined when the application runs
      return &lt;p&gt; {x} &lt;/p&gt;
  }
  
  export default TestComponent;
  </code></pre>
  
  <p>I am not sure if this error is to do with hot reloading, webpack, or something else entirely.</p>
  
  <p><strong>Package versions:</strong></p>
  
  <pre><code>// react
  "@types/react": "^16.9.9",
  "react": "^16.10.2",
  
  // redux
  "@types/react-redux": "^7.1.5"
  "react-redux": "^7.1.3",
  "redux": "^4.0.5", 
  </code></pre>
  
  <p><strong>What I have attempted:</strong></p>
  
  <p>1) Updated all redux packages to latest versions</p>
  
  <p>2) Deleted <code>node_modules</code> and reinstalled</p>
  
  <p>3) Updated hot reloading packages to latest versions</p>
  
  <p>4) Looking into the code of <code>react-redux</code> in <code>node_modules</code>, it does have the <code>useSelector</code> hook, but if I do the following: <code>import * as ReactRedux from 'react-redux';</code> and then <code>console.log(ReactRedux)</code>, I see the following, indicating none of the hooks have been imported:</p>
  
  <p><a href="https://i.stack.imgur.com/YGWTC.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/YGWTC.png" alt="enter image description here"></a></p>