MCPcopy
hub / github.com/TanStack/query / queryFn

Function queryFn

packages/react-query/src/__tests__/useQuery.test.tsx:2373–2376  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

2371 const key = queryKey()
2372
2373 const queryFn = async () => {
2374 await sleep(10)
2375 return 'data1'
2376 }
2377
2378 function Page() {
2379 useQuery({ queryKey: key, queryFn, retryDelay: 10 })

Callers 1

PageFunction · 0.70

Calls 3

sleepFunction · 0.90
rejectFunction · 0.85
resolveFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…