product-card
This commit is contained in:
@@ -1,2 +1,3 @@
|
||||
export * from './useGetProductsDetail'
|
||||
export * from './useGetProductsList'
|
||||
export * from './useGetProductsVariationsList'
|
||||
|
||||
10
api/queries/useGetProductsList.ts
Normal file
10
api/queries/useGetProductsList.ts
Normal file
@@ -0,0 +1,10 @@
|
||||
import { useQuery } from '@tanstack/vue-query'
|
||||
import { getProductsList } from '~/api/endpoints/getProductsList'
|
||||
|
||||
export const useGetProductsList = () => {
|
||||
return useQuery({
|
||||
queryKey: ['get-products-list'],
|
||||
queryFn: () => getProductsList(),
|
||||
staleTime: Infinity,
|
||||
})
|
||||
}
|
||||
Reference in New Issue
Block a user