MCPcopy Index your code
hub / github.com/TanStack/query / Suspended

Function Suspended

packages/react-query/src/__tests__/usePrefetchQuery.test.tsx:38–50  ·  view source on GitHub ↗
(props: {
    queryOpts: UseSuspenseQueryOptions<TData, Error, TData, Array<string>>
    children?: React.ReactNode
  })

Source from the content-addressed store, hash-verified

36 })
37
38 function Suspended<TData = unknown>(props: {
39 queryOpts: UseSuspenseQueryOptions<TData, Error, TData, Array<string>>
40 children?: React.ReactNode
41 }) {
42 const state = useSuspenseQuery(props.queryOpts)
43
44 return (
45 <div>
46 <div>data: {String(state.data)}</div>
47 {props.children}
48 </div>
49 )
50 }
51
52 it('should prefetch query if query state does not exist', async () => {
53 const queryOpts = {

Callers

nothing calls this directly

Calls 1

useSuspenseQueryFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…