|
If by garbage collection you mean real-time, then no. Most browsers
will cleanup pretty thoroughly when you refresh or load a new page, but
in the scope of a single page there is very little GC. Try this page
that I setup a few weeks ago to test various Event handling libraries:
(disable Firebug for most consistent results) http://colin.mollenhour.com/events/test.html?rev=hybrid Open Task Manager or whatever memory monitoring tool you use and click "Create Elements", now click "Make ToolTips". Ok, memory usage went up quite a bit. Now click "Cleanup" and then "Clear". Memory usage probably didn't go down, but that isn't leaked memory it is just memory that seems to be allocated to that page still, because if you repeat the above steps again it won't go up any more this time. Now reload the page and you're back to what you started with roughly. However, if you repeat the above steps two or more times but forgetting to click "Cleanup", the memory usage for that page will go up more each time. You'll still get it all back when you reload the page again, but that is what I'm referring to when I say memory leaks. For many sites it isn't so critical because they may have a shorter lifetime or simply not much memory usage to begin with, but I try to design everything in such a way that it would scale in the worst of circumstances. Your original problem was non-unique ids.. you were copying the innerHTML of a node that contained another node with an id specified so it was trying to create a second node with the same id. I think FF and IE handle this differently but it would have cropped up as a problem in FF eventually as well. Colin David Welton wrote: On 2/27/07, Colin Mollenhour <[EMAIL PROTECTED]> wrote:Hi, thanks for your extensive response! --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs?hl=en -~----------~----~----~----~------~----~------~--~--- |
