MCPcopy Create free account
hub / github.com/TanStack/query / fetchData

Function fetchData

packages/query-core/src/__tests__/queryClient.test.tsx:62–62  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

60 })
61
62 const fetchData = () => Promise.resolve('data')
63 await testClient.prefetchQuery({ queryKey: key, queryFn: fetchData })
64 const newQuery = testClient.getQueryCache().find({ queryKey: key })
65 expect(newQuery?.options.gcTime).toBe(Infinity)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected