title: Typescript Select Ids from object
body: <p>I am new to Typescript. I want to select ids from observable</p>
  
  <p>This is my observable</p>
  
  <pre><code>let myObj = [{
    "id": 1,
    "text": "Mary"
  }, {
    "id": 2,
    "text": "Nancy"
  }, {
    "id": 3,
    "text": "Paul"
  }, {
    "id": 4,
    "text": "Cheryl"
  }, {
    "id": 5,
    "text": "Frances"
  }]
  </code></pre>
  
  <p>Expected Result :</p>
  
  <pre><code>let selectedIds = [1,2,3,4,5];
  </code></pre>
  
  <p>Can I do this without creating an array and pushing the ids in a for loop. </p>