MCPcopy
hub / github.com/simstudioai/sim / destroy

Method destroy

apps/sim/lib/pptx-renderer/core/viewer.ts:436–456  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

434 // -----------------------------------------------------------------------
435
436 destroy(): void {
437 this.teardownAdaptiveResize()
438 this.cleanupScrollObserver?.()
439 this.cleanupScrollObserver = undefined
440 this.cleanupListMount?.()
441 this.cleanupListMount = undefined
442 this.ensureListSlideMountedFn = undefined
443 this.mountedSlides.clear()
444 for (const handle of this.slideHandles.values()) {
445 handle.dispose()
446 }
447 this.slideHandles.clear()
448 this.disposeAllCharts()
449 for (const url of this.mediaUrlCache.values()) {
450 URL.revokeObjectURL(url)
451 }
452 this.mediaUrlCache.clear()
453 this.container.innerHTML = ''
454 this.presentation = null
455 this.activeRenderMode = null
456 }
457
458 [Symbol.dispose](): void {
459 this.destroy()

Callers 2

openMethod · 0.95
[Symbol.dispose]Method · 0.95

Calls 4

disposeAllChartsMethod · 0.95
clearMethod · 0.65
disposeMethod · 0.65

Tested by

no test coverage detected