Topic: Bug draggable plugin: please turn off "resize" in dispose()

cdc free asked 2 years ago

Actual behavior

Resize event is turn on, but does not turn off in dispose...

and therefore it generates multiple errors once the element has been disposed.


_dragTriggers() {
    EventHandler.on(this.dragEl, 'touchstart', this._dragStart);
    EventHandler.on(this.dragEl, 'mousedown', this._dragStart);
    EventHandler.on(window, 'resize', this._takeAgainCoordinates); 

dispose() {, 'touchstart', this._dragStart);, 'mousedown', this._dragStart);
    Data.removeData(this._element, DATA_KEY);
    this._element = null;  }

Expected behavior

    dispose() {, 'touchstart', this._dragStart);, 'mousedown', this._dragStart);
        Data.removeData(this._element, DATA_KEY);, 'resize', this._takeAgainCoordinates); // <= *THIS*

        this._element = null; }


Michał Duszak staff answered 2 years ago

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

Please insert min. 20 characters.


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



Specification of the issue

  • ForumUser: Free
  • Premium support: No
  • Technology: MDB Standard
  • MDB Version: MDB5 3.8.1
  • Device: macbook pro
  • Browser: chrome
  • OS: big sur
  • Provided sample code: No
  • Provided link: No