Here I am having the onclick function which is get the `Product_id`, `Product_name` and `Price` from detailss array. I am storing this value using local storage array wishlist.

Now I am stuck to update the quantity in local storage array wishlist,
I need to add the quantity if the productid already present in local storage.

```
addToCart(Product_id){

    var name=[{
        Product_id:this.detailss[0].Product_id,
        Product_name:this.detailss[0].Product_name,
        Price:this.detailss[0].Price,
        Quantity:"",

    }];

var a = JSON.parse(localStorage.getItem('wishlist')) || [];
a.push(name);
localStorage.setItem('wishlist', JSON.stringify(a));
console.log(Product_id);

}

```

Thanks in advance.