I am using the addToCart() function to increase the quantity in Wix Cart and Cart Icons from my customize cart’s items.
How can I reduce the quantity in Wix Cart and Cart Icons from my customize cart’s items, when I try to use addToCart(productId, Quantity), where Quantity = -1. I am getting the below error:
FetchError: {"code":"ERROR_INVALID_COMMAND_FIELD","commandName":"AddCartItemCommand","message":"got -1, expected more than 0","field":"quantity with value \"-1\" got -1, expected more than 0"}
I am sure, there should be another way to reduce the quantity using Corvid as well. Please suggest.