[Vuejs]-Sum two items in table row

0👍

Sounds like you’ll want to iterate the ‘items’ and sum the properties of each ‘item’.

The below code will return an array of integers, but you could format the array values however you want, just edit what is returned from the map function.

computed: {
    total: function() {
      return this.items.map(i => {
        return parseInt(i.disburs*m*nt) + parseInt(i.price)
      }
}

Leave a comment