Newbie in the world of JavaScript and VUE.
In my data, I have a variable called numberOfItems
with a value of 10
.
I am trying to check if this value is equal to the total sum of 5
different variables.
var numberOfItems = 10
var destinations = (this.campaign.shipments_ue + this.campaign.shipments_uk + this.campaign.shipments_islas + this.campaign.shipments_peninsula + this.campaign.shipments_international)
Instead of getting 10
, I'm receiving 22222
as the value for destinations
. Can anyone suggest a method to correctly add them up for comparison?
Appreciate any help!