Please try not use $(element).data() in Widget.

Please try not use $(element).data() in Widget.

The $(element).data() call is very expensive because it triggers setData/getData events, which in turn make some other .datat() calls. If the events are not needed, please use $.data(element, key, val) call which are much faster.

The jquery Widget has one expensive $(element).data() call on _createWidget:function(). This make creating hundreds of widget very slow. Please replace:
               this.element = $( element ).data( this.widgetName, this );
               this.element = $( element );
               $.data(element, this.widgetName, this );

Actually, many .data calls in the Widget use the $.data() form which is good.

But most such calls in the Draggable code use the evil $(this).data() call.

Someone should clean up all the other UI .js for the slow and unnecessary $(this).data() calls.