var arr = rowspan.get();
["2", "2", "2"] = ?
const s = arraySum([]);
console.log(s);
function arraySum(arr) {
let sum = 0;
if (arr.length) {
sum = arr.reduce((a, b) => {
return (parseFloat(a) || 0) + (parseFloat(b) || 0);
});
} else {
sum = 0;
}
return sum;
}