MCPcopy Create free account
hub / github.com/dailydotdev/apps / isRootFeed

Function isRootFeed

packages/shared/src/components/shell/shellRefresh.ts:28–31  ·  view source on GitHub ↗
(query: Query)

Source from the content-addressed store, hash-verified

26// The root's list, not the page: a paged query on screen that is not an ad
27// request. Everything else mounted (boot, streak, ads) is left alone.
28const isRootFeed = (query: Query): boolean =>
29 Array.isArray(
30 (query.state.data as { pages?: unknown[] } | undefined)?.pages,
31 ) && query.queryKey[0] !== RequestKey.Ads;
32
33// Back to the first page, then refetch it in place. A reset would empty the
34// query first: the feed fell back to its placeholders and a row built from

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected