I use the innerHTML solution for a similar problem because direct DOM manipulation is very slow.  however, I have read some articles that indicate that using a documentFragment should be much faster - i.e create the document fragment, add all of your elements, and then put the fragment back in the active tree.  I would be interested to hear any success or failure stories.



On 2/13/06, Bob Ippolito <[EMAIL PROTECTED]> wrote:


On Feb 13, 2006, at 7:27 AM, gbirke wrote:

> I use MochiKit for an online store. When I show big tables (6 columns,
> 3500 rows) the page becomes very slow and Firefox asks me if it should
> kill an unresponsive script. I'm only including the Base, Iter, Async
> and DOM files on that page, functions only get called, when someone
> clicks on a link.
>
> Is there any explanation for this? Any solution (except not showing so
> many entries)?

You'll need to show the code if you want any useful answer,
preferably in the context of a working example.

Generically the answer is "DOM is slow if you do it wrong." and
sometimes "DOM is slow period, maybe you'll need to drop back to
building HTML and using innerHTML", but unless it's profiled there's
no way to know what can be improved upon.

-bob


Reply via email to