[jQuery] Jquery plugin design question
I hope this isn't so obvious that i'm just missing the point. I'm
working on a couple of plugins that all have the following basic
design :
jQuery.fn.Text = function () {
return this.each( function() {
//some code
function someFunction() {
}
});
};
When I use the plugin ('#element').Text() everything works perfectly.
The element is transformed but my question is how do I retain a
reference to the functions defined within the plugin return loop. Can
I assign the return of .Text() to a variable and then call
someFunction? Am I making any sense?
thanks