How can I check to see if a jQuery UI plugin is attached to an element? For example, if I load up the .sortable widget, how can its presence be determined?
The purpo
All ui widgets attach their name as true to the element's container data. jqueryui also adds a data filter expression.
var $elem = $('div.sortable-container:data(sortable)'); if ($elem.length){ // $elem contains list of elements that have sortable widget attached }