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

Class

packages/query-devtools/src/__tests__/Devtools.test.tsx:71–90  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

69 vi.stubGlobal(
70 'ResizeObserver',
71 class {
72 callback: ResizeObserverCallback
73 constructor(callback: ResizeObserverCallback) {
74 this.callback = callback
75 resizeObservers.push(this)
76 }
77 observe = vi.fn<(target: Element) => void>((target: Element) => {
78 this.callback(
79 [
80 {
81 target,
82 contentRect: { width: 1000, height: 500 } as DOMRectReadOnly,
83 } as ResizeObserverEntry,
84 ],
85 this,
86 )
87 })
88 unobserve = vi.fn<ResizeObserver['unobserve']>()
89 disconnect = vi.fn<ResizeObserver['disconnect']>()
90 },
91 )
92 queryClient = new QueryClient()
93 document.documentElement.style.fontSize = '16px'

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected