Topic: Memory Leaks (at least in Select) and MutationObserver bugs

Expected behavior

No memory leaks (Detached Elements)

Actual behavior

Memory leaks caused by select. Dispose not cleaning up properly

Resources (screenshots, code snippets etc.)

If I dont set private members to null the select Element does not get garbage collected:

oldSelect.dispose();

oldSelect._element = null;

oldSelect._activeOption = null;

oldSelect._plainOptions = null;

oldSelect._optionsToRender = null;

oldSelect._selectionModel = null;


There are also issues with MutationObserver. The method _disconnectMutationObserver is never called and it references an undefined variable:

this.mutationObserver instead of this._mutationObserver

_disconnectMutationObserver() {
    if (this.mutationObserver) {
      this._mutationObserver.disconnect();
      this._mutationObserver = null;
    }
  }

Michał Duszak staff answered 3 years ago


Hello, thank you for your feedback. We will fix this asap.



Please insert min. 20 characters.

FREE CONSULTATION

Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.

Status

Answered

Specification of the issue

  • ForumUser: Premium
  • Premium support: Yes
  • Technology: MDB Standard
  • MDB Version: MDB5 3.9.0
  • Device: All
  • Browser: All
  • OS: All
  • Provided sample code: No
  • Provided link: No