mirror of
https://github.com/vercel/commerce.git
synced 2025-09-08 00:40:15 +00:00
Minor changes
This commit is contained in:
@@ -10,9 +10,7 @@ const defaultOpts = {
|
||||
method: 'GET',
|
||||
}
|
||||
|
||||
type UseCartResponse = BigcommerceCart & Cart
|
||||
|
||||
export const fetcher: HookFetcher<UseCartResponse | null, CartInput> = (
|
||||
export const fetcher: HookFetcher<BigcommerceCart | null, CartInput> = (
|
||||
options,
|
||||
{ cartId },
|
||||
fetch
|
||||
@@ -22,7 +20,7 @@ export const fetcher: HookFetcher<UseCartResponse | null, CartInput> = (
|
||||
|
||||
export function extendHook(
|
||||
customFetcher: typeof fetcher,
|
||||
swrOptions?: SwrOptions<UseCartResponse | null, CartInput>
|
||||
swrOptions?: SwrOptions<BigcommerceCart | null, CartInput>
|
||||
) {
|
||||
const useCart = () => {
|
||||
const response = useCommerceCart(defaultOpts, [], customFetcher, {
|
||||
|
Reference in New Issue
Block a user