I have got an object with two arrays:
{
names: ["aa", "bb", "cc", "dd", "ee", "ff"],
price: [3,6,2,7,1,9]
}
I need to sort price
but also I need that names
also to be sorted.
{
names: ["ee", "cc", "aa", "bb", "dd", "ff"],
price: [1,2,3,6,7,9]
}