To Extend Or Wrap?

To Extend Or Wrap?

I recently created a set of widgets that "use" some of the default jQuery UI widgets but the method I use is wrapping. I would like your feedback on this approach and it's pros and cons. 

My example - I have a page selector widget that uses sortable for ordering:

Rather than extend the sortable widget I wrote my code so that sortable was invoked from within my widget.

So in my _create I have something like like this:

var self = this, o = this.options, e = this.element;

And the sortable options are set in my widgets options{}. 

I'm a little hazy on best practices for extending/wrapping and when to use them. This is one area where I can not find any (good) blog posts or documentation for direction

Any feedback or pointers is appreciated.