📜  如何反转对象数组 - CSS 代码示例

📅  最后修改于: 2022-03-11 14:48:00.343000             🧑  作者: Mango

代码示例2
var x = [{"score":1},{"score":2},{"score":3}]
console.log(x);

var y = x.reverse();
console.log(y);

if the above method does not work than try this

var y = [...x].reverse();
console.log(y);