tr(v-for="product in filteredProducts" class="table-active"
@click="$set(product, 'quantity', product.quantity || 1), buttonDisabled = false"
:class="{activeTh: cart.includes(product)}" :disabled="(cart.includes(product))")
td
img(v-bind:src="product.img" class="imgs")
td {{product.title}}
td {{product.price}}
filteredProducts() {
const s = this.search.toLowerCase();
return this.products.filter(n => Object.values(n).some(m => m.toString().toLowerCase().includes(s)));
},
priceProduct(){
var prc = this.products.reduce((product) => parseFloat(product.price), 0);
return parseFloat(prc).toFixed(2).replace(/(\d)(?=(\d{3})+\.)/g, "$1 ").replace('.', ',');
},