How to reduce the cart quantity using Corvid?

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.

Hey,

Currently, the desired functionality is not available. Your feedback is highly appreciated and has been forwarded to the relevant department.

At Wix, we are constantly working to improve and update existing features and introduce new ones. The latest Corvid updates can be found here and the current Corvid Wishlist here .

See the current features in development here or request your own here .

As a workaround you could build your own store without the wix-stores API and this post will show you how to set up a remove from cart function.

Hope this helps!

Dara | Corvid Team