Updates the current site visitor's cart.
The updateCurrentCart()
function returns a Promise that resolves when the current cart's properties are updated.
Note: When updating catalog items, options.lineItems.catalogReference
is required.
function updateCurrentCart(options: UpdateCurrentCartOptions): Promise<Cart>;
Current cart update options.
import { currentCart } from "@wix/ecom";
async function updateCurrentCart(options) {
const response = await currentCart.updateCurrentCart(options);
}
This method doesn’t return any custom errors, but may return standard errors. Learn more about standard Wix errors.