UNPKG

@qbcart/eshop-cart-hooks

Version:

Type to hooks for manipulating the shopping cart across the QBCart EShop ecosystem.

15 lines (14 loc) 536 B
/** * @license * Copyright (c) 2021 QBCart Inc. All rights reserved. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source repo. */ /** * Hook for updating an item in the cart. * @param {boolean} userLoggedIn - Whether to use userCart or guestCart. * @return A function for updating an item in the cart. */ declare const useUpdateCart: (userLoggedIn: boolean) => (id: string, price: number, quantity: string) => Promise<boolean>; export default useUpdateCart;