Jquery access to $(this) inside a plugin
<p>Is there any way to get an access to $(this) when the plugin is initialized? for example I have a plugin resizable where I need access to an element that is being resized, so I could use it later in a method that is declared inside a plugin</p>

<pre><code>$('.someClass').resizable({  
  resize:function(event, ui) {
   $(this).doSomeStuff() //how to get access to $(this)? Where it should be declared?
  }
})
</code></pre>

<p>I've figured out the solution:</p>

<pre><code>$('.someClass').each(function(){ 
  var me = $(this); 
  $(me).resizable({     
    resize: function(event, ui) { 
          $(me).doSomeStuff();
        }
   });
});
</code></pre>

<p>All that it took just to make sure the plugin is inside of $('').each() method</p>
