From 1a7ae434b71d656dc89fbbd6c8c64b6959390869 Mon Sep 17 00:00:00 2001 From: ajnart Date: Wed, 5 Apr 2023 14:42:22 +0900 Subject: [PATCH] Raise cache time for ReactQuery --- src/widgets/rss/RssWidgetTile.tsx | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/widgets/rss/RssWidgetTile.tsx b/src/widgets/rss/RssWidgetTile.tsx index 5f1ee2c57..fa2ed14ff 100644 --- a/src/widgets/rss/RssWidgetTile.tsx +++ b/src/widgets/rss/RssWidgetTile.tsx @@ -51,6 +51,8 @@ interface RssTileProps { export const useGetRssFeeds = (feedUrls: string[], widgetId: string) => useQuery({ queryKey: ['rss-feeds', feedUrls], + // Cache the results for 24 hours + cacheTime: 1000 * 60 * 60 * 24, queryFn: async () => { const responses = await Promise.all( feedUrls.map((feedUrl) =>