Javascript cum de a comanda o serie de mai multe params
Exemple de cod
1
0
un fel serie de obiecte de 2 valoare-cheie
homes.sort(
function(a, b) {
if (a.city === b.city) {
// Price is only important when cities are the same
return b.price - a.price;
}
return a.city > b.city ? 1 : -1;
});