Quantcast
Channel: JavaScriptMVC Forum
Viewing all articles
Browse latest Browse all 3491

Can.Observe.List needs a sort().

$
0
0
Presently, Can.Observe.List has methods to join two lists and reverse the list:

  can.extend(list.prototype, {
    join : [].join,
    reverse: [].reverse,
}

Support for sorting is absent, but a very simple patch would enable sorting, wouldn't it?

  can.extend(list.prototype, {
    join : [].join,
    reverse: [].reverse,
    sort: [].sort,
 }

/Cajo.

Viewing all articles
Browse latest Browse all 3491

Trending Articles