mirror of
https://github.com/omnivore-app/omnivore.git
synced 2026-03-11 08:54:26 +00:00
Merge pull request #4263 from omnivore-app/fix/web-library-refetch
Set a stale time to try to prevent over fetching
This commit is contained in:
commit
706e972095
1 changed files with 3 additions and 1 deletions
|
|
@ -230,8 +230,10 @@ export function useGetLibraryItems(
|
|||
return response.search
|
||||
},
|
||||
enabled,
|
||||
refetchOnMount: false,
|
||||
initialPageParam: '0',
|
||||
refetchOnMount: false,
|
||||
refetchOnWindowFocus: false,
|
||||
staleTime: 10 * 60 * 1000,
|
||||
getNextPageParam: (lastPage: LibraryItems) => {
|
||||
return lastPage.pageInfo.hasNextPage
|
||||
? lastPage?.pageInfo?.endCursor
|
||||
|
|
|
|||
Loading…
Reference in a new issue