What's the best way to load HTML markup for a custom jQuery UI widget?
So far, I've seen elements simply created using strings (i.e. $(...).wrap('<div></div>')
) which is fine for something simple. However, this makes it extremely difficult to modify later for more complex elements.
This seems like a fairly common problem, but I also know that the jQuery UI library is new enough that there may not be a widely accepted solution for this. Any ideas?