Edit this page


Prepares the Button for safe removal from DOM. Detaches all event handlers and removes jQuery.data attributes to avoid memory leaks. Calls destroy method of any child Kendo widgets.

Important: This method does not remove the Button element from DOM.


<div data-role="view">
  <a id="btn" data-role="button">Foo</a>
  <a data-role="button" data-click="removeBtn">Remove button</a>

  var app = new kendo.mobile.Application();

  function removeBtn() {
    $("#btn").data("kendoMobileButton").destroy(); //detach events
Is this article helpful? Yes / No
Thank you for your feedback!

Give article feedback

Tell us how we can improve this article