title: Difference between of "K extends keyof T" vs. directly using "keyof T"?
body: <p>Is there any difference between the following typescript definitions:</p>
  
  <pre><code>function prop&lt;T, K extends keyof T&gt;(obj: T, key: K) {
      return obj[key];
  }
  </code></pre>
  
  <p>and</p>
  
  <pre><code>function prop2&lt;T&gt;(obj: T, key: keyof T) {
      return obj[key];
  }
  </code></pre>
  
  <p>I mean no, but maybe I have overseen something. Are there any benefits to use the first version (which is often used in the docs)</p>