title: Sorting An Array Inside An Array Of Objects
body: <p>Hello I have an array of this form which I am displaying on my meteor template.</p>
  
  <pre><code>var data = [{text_name:'My life', 
  score: [{name : 'james',score: 10}, 
          {name : 'john',score : 40},  
          {name : 'Abu',score : 80}]},
          {text_name:'The game real', 
  score: [{name : 'penny',score: 30} 
          {name : 'john',score : 20} , 
          {name : 'Abu',score : 30}] }]
  </code></pre>
  
  <p>I want to sort the <code>score</code> key which is an array of objects in descending order. Using the example data in the <code>text_name:'My life'</code> I want Abu scores to display first because he scored highest.</p>
  
  <p>I have tried sorting by using the code found on this link <a href="https://stackoverflow.com/questions/979256/sorting-an-array-of-javascript-objects">Sorting an array of JavaScript objects</a>.</p>