title: Generic arrow function component with inteface "Cannot find name 'T'"
body: <p>I got an error when I'm trying to write a generic arrow function (see code below) :</p>
  <pre><code>
  interface AutocompleteModalProps&lt;T&gt; {
    isVisible: boolean;
    searchMethod: (value: string) =&gt; T;
    renderItem: (item: T) =&gt; ReactNode;
    children: ReactNode;
  }
  
  
  // Error on the 'T' =&gt; &quot;Cannot find name 'T'&quot;
  
  const AutocompleteModal: React.FC&lt;AutocompleteModalProps&lt;T&gt;&gt; = ({
    isVisible,
    children,
    renderItem,
    searchMethod,
  }) =&gt; {
  ...
  };
  </code></pre>
  <p>The &quot;function&quot; way is working, but I have to transform it to an arrow function...</p>
  <pre><code>
  function OldWay&lt;T&gt;({
    isVisible,
    searchMethod,
    renderItem,
    children,
  }: AutocompleteModalProps&lt;T&gt;) {
  
  </code></pre>