Duplicated
Last Updated: 25 Mar 2021 12:18 by ADMIN
Yann
Created on: 22 May 2013 23:08
Category: MVVM
Type: Feature Request
49
Allow to sort an ObservableArray
Allow to sort an ObservableArray

The current work around is to use the native array function

Array.prototype.sort.call(myArray, myComparer);
Duplicated
This item is a duplicate of an already existing item. You can find the original item here:
2 comments
Yann
Posted on: 24 May 2013 19:49
It will feel more natural instead of always having to think that in the back you transform everything in an ObservableObject or ObservableArray.

And myArray.sort(myComparer) is also easier to read.
ADMIN
Brandon
Posted on: 24 May 2013 19:34
Hi Yann,

If we provided an implementation, we'd likely do something similar, so while I'm not sure it would save you much, I'll leave this one open to see if others want to vote this one up.