mercredi 8 avril 2015

How do I display the sum of multiple properties in Ractive


Vote count:

0




I am using RactiveJS for my templates. I have some nested data like this:



var view = new Ractive({
data: {
items: [
{ size: 1 }
{ size: 3 }
{ size: 4 }
]
}
});


How can I display the sum of item sizes in my template? This depends on the size of each individual item but also on the items array (e.g. items are added/removed).



asked 1 min ago







How do I display the sum of multiple properties in Ractive

Aucun commentaire:

Enregistrer un commentaire