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

Class

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

Source from the content-addressed store, hash-verified

81 vi.stubGlobal(
82 'ResizeObserver',
83 class {
84 callback: ResizeObserverCallback
85 constructor(callback: ResizeObserverCallback) {
86 this.callback = callback
87 resizeObservers.push(this)
88 }
89 observe = vi.fn<(target: Element) => void>((target: Element) => {
90 this.callback(
91 [
92 {
93 target,
94 contentRect: { width: 1000, height: 500 } as DOMRectReadOnly,
95 } as ResizeObserverEntry,
96 ],
97 this,
98 )
99 })
100 unobserve = vi.fn<ResizeObserver['unobserve']>()
101 disconnect = vi.fn<ResizeObserver['disconnect']>()
102 },
103 )
104 queryClient = new QueryClient()
105 document.documentElement.style.fontSize = '16px'

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected