title: React.forwarRef breaks vscode's autocomplete for propTypes
body: <p>Here is my approach.</p>
  <p>If there is no <code>forwardRef</code>:</p>
  <pre><code>import PropTypes from &quot;prop-types&quot;;
  import { forwardRef } from &quot;react&quot;;
  
  const Test = (props) =&gt; {
    return &lt;div&gt;{props.text}&lt;/div&gt;;
  };
  
  Test.propTypes = {
    text: PropTypes.string.isRequired,
    src: PropTypes.string
  };
  Test.displayName = &quot;Test&quot;;
  
  // use Test in useText
  function useText() {
    return &lt;Test /&gt;;
  }
  </code></pre>
  <p>I can get the autocomplete from vscode like this:
  <a href="https://i.stack.imgur.com/qS7bH.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/qS7bH.png" alt="enter image description here" /></a></p>
  <p>BUT, when there is <code>forwardRef</code>:</p>
  <pre><code>import PropTypes from &quot;prop-types&quot;;
  import { forwardRef } from &quot;react&quot;;
  
  const Test = forwardRef((props, ref) =&gt; {
    return &lt;div&gt;{props.text}&lt;/div&gt;;
  });
  
  Test.propTypes = {
    text: PropTypes.string.isRequired,
    src: PropTypes.string
  };
  Test.displayName = &quot;Test&quot;;
  
  function useText() {
    return &lt;Test /&gt;;
  }
  </code></pre>
  <p>Nothing I can get from vscode autocomplete:
  <a href="https://i.stack.imgur.com/koOM4.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/koOM4.png" alt="enter image description here" /></a></p>
  <p>So I wonder is there a way to fix this?</p>