title: What is the javascript equivalent of numpy argsort?
body: <p>I want to sort the imgUrl array by click count. I have two arrays.</p>
  
  <pre><code>clickCount = [5,2,4,3,1]
  imgUrl     = ['1.jpg','2.jpg','3.jpg','4.jpg','5.jpg']
  </code></pre>
  
  <p>In numpy it is easy. I use <code>order = np.argsort(clickCount)</code> then I create another array <code>newArray = [imgUrl[i] for i in order]</code>.</p>
  
  <p>How do I achieve the same effect in javascript (preferably vanilla)? </p>