Add MAX_PAGING_RESULTS on hooks for performance improvements.
This commit is contained in:
1 parent
a8c1f26775
commit
fbac7518fc
17 files changed
+74
-215
No files matched your search
@@ -1,3 +1,4 @@
|
||||
import { MAX_PAGING_RESULTS } from '@/lib/constants';
|
||||
import type { ReactQueryOptions } from '@/lib/types';
|
||||
import { useApi } from '../useApi';
|
||||
import { useDateParameters } from '../useDateParameters';
|
||||
@@ -32,6 +33,7 @@ export function useWebsiteEventsQuery(
|
||||
...filters,
|
||||
...pageParams,
|
||||
eventType: EVENT_TYPES[params.view],
|
||||
maxResults: MAX_PAGING_RESULTS,
|
||||
}),
|
||||
enabled: !!websiteId,
|
||||
...options,
|
||||
|
||||
Reference in new issue
Block a user