Skip to content

Commit

Permalink
fix: disable prefetch & refetch for testing
Browse files Browse the repository at this point in the history
  • Loading branch information
kwiss committed Jun 29, 2024
1 parent ba5569e commit 57502d2
Show file tree
Hide file tree
Showing 6 changed files with 5,037 additions and 3,930 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ export default function CollectionItemsDataGridView({
<Link
href={`/token/${collectionToken.contract}/${collectionToken.token_id}`}
key={`${collectionToken.contract}-${collectionToken.token_id}`}
prefetch={false}
>
<NftCard>
<NftCardMedia>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ export default function CollectionItemsDataListView({

return (
<Link
prefetch={false}
href={`/token/${token.contract}/${token.token_id}`}
key={`${token.contract}-${token.token_id}`}
>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ export default function CollectionItemsData({
} = useInfiniteQuery({
// TODO @YohanTz: add filters states to query key
queryKey: ["collectionTokens", sortDirection, sortBy, collectionAddress],
refetchInterval: 10_000,
refetchInterval: false,
getNextPageParam: (lastPage) => lastPage.next_page,
initialData: {
pages: [collectionTokensInitialData],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ export default function Collection({

const { data: collectionInfos } = useQuery({
queryKey: ["collectionInfos", collectionAddress],
refetchInterval: 10_000,
refetchInterval: false,
initialData: collectionInfosInitialData,
queryFn: () => getCollectionInfos({ collectionAddress }),
});
Expand Down
3 changes: 1 addition & 2 deletions apps/arkmarket/src/app/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,7 @@ export default function HomePage() {
<Image
src={collection.image}
alt={collection.name}
layout="fill"
objectFit="cover"
fill
className="absolute left-0 top-0 h-full w-full"
/>
</CardContent>
Expand Down
Loading

0 comments on commit 57502d2

Please sign in to comment.