title: knockoutjs ObservableArrays and sort function: UI is not updated
body: <p>In my viewmodel, I have a knockoutjs ObserableArray. Just after I initialized the ViewModel, it binds the data successfully. Then, what I need to do is to sort the collection.</p>
  
  <pre><code>$.each(vm.searchResults(), function (i, property) {
      console.log(property.Name());
  });
  
  vm.searchResults().sort(function (a, b) {
      return a.Name().toLowerCase() &gt; b.Name().toLowerCase() ? 1 : -1;
  });
  
  $.each(vm.searchResults(), function (i, property) {
      console.log(property.Name());
  });
  </code></pre>
  
  <p>As you can see, I output the Name of the element to the console to see the order before and after the sorting. The sorting works just fine. The problem is with the UI update. Somehow, the UI is not updated. </p>
  
  <p>Then, try to remove a record from the array with the following code to see if the UI will respond to that or not:</p>
  
  <pre><code>vm.searchResults().shift();
  </code></pre>
  
  <p>The UI stays the the same and didn't update again. What would be the problem here?</p>
  
  <p><strong>Edit:</strong></p>
  
  <p>Here is a sample case as well: <a href="http://jsfiddle.net/tugberk/KLpwP/" rel="noreferrer">http://jsfiddle.net/tugberk/KLpwP/</a></p>
  
  <p>The same problem here as well.</p>
  
  <p><strong>Edit:</strong></p>
  
  <p>I solved the problem as shown in this sample: <a href="http://jsfiddle.net/tugberk/KLpwP/16/" rel="noreferrer">http://jsfiddle.net/tugberk/KLpwP/16/</a> But I am still not sure why it worked as I tried at first.</p>