How to sort list of dicts in js?
<blockquote>
  <p><strong>Possible Duplicate:</strong><br>
  <a href="http://stackoverflow.com/questions/979256/how-to-sort-an-array-of-javascript-objects">How to sort an array of javascript objects?</a>  </p>
</blockquote>



<p>How to sort list of dicts in js?</p>

<p>I have:</p>

<pre><code>[{'car': 'UAZ', 'price': 30 ,'currency': 'RUB'}, {'car': 'Mazda', 'price': 1000 ,'currency': 'USD'},{'car': 'Zaporozhec', 'price': 2 ,'currency': 'RUB'}, {'car': 'GAZ', 'price': 0 ,'currency': 'RUB'}]
</code></pre>

<p>I want to have it sorted by price and currency:</p>

<pre><code>[{'car': 'Mazda', 'price': 1000 ,'currency': 'USD'}, {'car': 'UAZ', 'price': 30 ,'currency': 'RUB'},{'car': 'Zaporozhec', 'price': 2 ,'currency': 'RUB'}, {'car': 'GAZ', 'price': 0 ,'currency': 'RUB'}]
</code></pre>
