Is it possible in jLinq to sort my data according to a defined function?
I would like to have something like:
var res = jLinq.from(data).orderBy(function (r) { return r.x + r.y; }).select();
Currently I have implemented this solution
var index = function (r) { return r.x + r.y; };
var res = jLinq.from(data).select();
res.sort(function(a,b){ return index(a)<=index(b) ? 1 : -1; });
but I was wondering if it is feasible in jLinq before the select