[jQuery] Re: empty().append() slow

2008-11-06 Thread Karl Rudd

Try making the selector more specific. So instead of $('.full') use
$('div.full').

Karl Rudd

On Fri, Nov 7, 2008 at 11:19 AM, jquertil [EMAIL PROTECTED] wrote:

 if I have a lot of elements inside div classfull.../div

 and then do $('.full').empty().append ('blah');

 it takes a long time. Is there a way to speed that up?


[jQuery] Re: empty().append() slow

2008-11-06 Thread jquertil

thanks Karl,

didn't make a difference. I suppose I'll have to preload everything
and show/hide things... ugh.

does empty() go through the entire element node tree and remove things
one by one or something? I kept thinking it just sets innerHTML=''.


[jQuery] Re: empty().append() slow

2008-11-06 Thread Brandon Aaron
It has to do more than just set innerHTML to a blank string to avoid memory
leaks. :(
--
Brandon Aaron

On Thu, Nov 6, 2008 at 6:28 PM, jquertil [EMAIL PROTECTED] wrote:


 thanks Karl,

 didn't make a difference. I suppose I'll have to preload everything
 and show/hide things... ugh.

 does empty() go through the entire element node tree and remove things
 one by one or something? I kept thinking it just sets innerHTML=''.