I am working on an interface which involves A LOT of javascript. There is a calendar and blocks drawn on the calendar.
The calendar is a jQuery widget, which works beautifully.
The blocks drawn on top are also jQuery widgets. While it works - I am wondering, every time I create another block, is the widget fully duplicating, or is it referencing the widget?
If I end up with 200 blocks on the screen, do I have 200 copies of the widget? Because if so i'm sure this will impact the performance quite heavily. Also it would determine whether I have functions inside the widget, or have them external to the widget looking in if that makes sense.
Just putting some feelers out there for thoughts. I couldn't find anything by searching online.