Skip to content

Commit

Permalink
Refresh data every 5 mins
Browse files Browse the repository at this point in the history
  • Loading branch information
P-man2976 committed Oct 14, 2023
1 parent a848623 commit f9a63dc
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/react/src/routes/home.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export function Home() {
const [tab, setTab] = useState("live");
const { data: live, isLoading: liveLoading } = useLive(
{ org, type: ["placeholder", "stream"], include: ["mentions"] },
{ enabled: tab === "live" },
{ refetchInterval: 1000 * 60 * 5, enabled: tab === "live" },
);
const {
data: archives,
Expand All @@ -33,6 +33,7 @@ export function Home() {
limit: 32,
},
{
refetchInterval: 1000 * 60 * 5,
enabled: tab === "archive",
},
);
Expand All @@ -51,6 +52,7 @@ export function Home() {
limit: 32,
},
{
refetchInterval: 1000 * 60 * 5,
enabled: tab === "clips",
},
);
Expand Down

0 comments on commit f9a63dc

Please sign in to comment.