The reduce() method can calculate totals from object properties. Set an initial value and accumulate from each object.
const items = [
{ price: 10 },
{ price: 20 },
{ price: 15 }
];
const total = items.reduce((sum, item) => sum + item.price, 0);
console.log(total); // 45
This sums all prices into a single number.