title: How to create a generic type for an arrow function in Typescript
body: <p>I try to write typescript functions in the style that is most close to functional. For simple functions I can write:
  </p>
  
  <pre><code>type A = (value: number) =&gt; string;
  const a: A = value =&gt; value.toString();
  </code></pre>
  
  <p>But what can I do with generic types? How can I type in that simple way following function?
  </p>
  
  <pre><code>function a&lt;T&gt;(value: T): T {
    return value;
  }
  </code></pre>
  
  <p>If I try to simply add a generic type, it gives nothing:
  </p>
  
  <pre><code>type A = &lt;T&gt;(value: T) =&gt; T;
  const a: A = value =&gt; value; // `value` implicitly has an `any` type
  </code></pre>
  
  <p>Is there any way to do it?</p>