documentation bug or question

2 posts, 0 answers
  1. Piyush Bhatt
    Piyush Bhatt avatar
    17 posts
    Member since:
    Oct 2014

    Posted 01 Jun Link to this post

    On this page - there is code to close the window as below.

    http://docs.telerik.com/kendo-ui/controls/layout/window/how-to/add-close-button

      $(".close-button").click(function(){// call 'close' method on nearest kendoWindow $(this).closest("[data-role=window]").kendoWindow("close");});

     

    Question - is kendoWindow("close") a proper call? or data("kendoWindow").close() would be right way to code here? This is in your documentation so making sure what is suggested approach.

  2. Dimiter Madjarov
    Admin
    Dimiter Madjarov avatar
    2153 posts

    Posted 03 Jun Link to this post

    Hello Piyush Bhatt,

    Yes, the two calls are internally equivalent, but we generally recommend the usage of

    data("kendoWindow").close()

    Thank you for pointing this example. We will modify it to use this type of invocation to remove the confusion.

    Regards,
    Dimiter Madjarov
    Telerik
     
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
     
  3. Kendo UI is VS 2017 Ready
Back to Top