@internal
(observer: MutationObserver<any, any, any, any>)
| 198 | |
| 199 | /** @internal */ |
| 200 | removeObserver(observer: MutationObserver<any, any, any, any>): void { |
| 201 | this.#observers = this.#observers.filter((x) => x !== observer) |
| 202 | |
| 203 | this.scheduleGc() |
| 204 | |
| 205 | this.#mutationCache.notify({ |
| 206 | type: 'observerRemoved', |
| 207 | mutation: this, |
| 208 | observer, |
| 209 | }) |
| 210 | } |
| 211 | |
| 212 | protected optionalRemove() { |
| 213 | if (!this.#observers.length) { |