- Source:
- See:
Example
var collection = new KagoDB({storage: 'memory'});
var obop = collection.obop();
var list = [
{ name: "apple", price: 50 },
{ name: "orange", price: 10 },
{ name: "pineapple", price: 70 },
{ name: "grape", price: 30 }
];
var order = { price: 1 };
var out2 = list.sort(obop.order(order));
console.log(out2);