mirror of
https://github.com/fallenbagel/jellyseerr.git
synced 2026-01-06 22:58:09 -05:00
fix: disable first page revalidation in useSWRInfinite (#1386)
By default, useSWRInfinite revalidates the first page every time a new page is loaded, resulting in additional requests being sent. This PR disables this behavior. fix #1380
This commit is contained in:
@@ -56,6 +56,7 @@ const MediaSlider = ({
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
initialSize: 2,
|
initialSize: 2,
|
||||||
|
revalidateFirstPage: false,
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|||||||
@@ -80,6 +80,7 @@ const useDiscover = <
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
initialSize: 3,
|
initialSize: 3,
|
||||||
|
revalidateFirstPage: false,
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user