| 17 | vi.stubGlobal( |
| 18 | 'ResizeObserver', |
| 19 | class { |
| 20 | targets = new Set<Element>() |
| 21 | constructor(callback: ResizeObserverCallback) { |
| 22 | observers.push({ callback, observer: this, targets: this.targets }) |
| 23 | } |
| 24 | observe(target: Element) { |
| 25 | this.targets.add(target) |
| 26 | } |
| 27 | unobserve(target: Element) { |
| 28 | this.targets.delete(target) |
| 29 | } |
| 30 | disconnect() { |
| 31 | this.targets.clear() |
| 32 | } |
| 33 | }, |
| 34 | ) |
| 35 | }) |
| 36 |
nothing calls this directly
no outgoing calls
no test coverage detected