News for hackers. Stuff that matters.
Re:The DOM isn't slow by mikepurvis on Tuesday March 19, 2013 @10:55AM (#5401230)
Interesting. On a whim, I tried changing your fiddle to use Array.join construction rather than string appends, but string appends remain 5-10% faster:

http://jsfiddle.net/2kWdC/

That way uses an indexed for-loop, but the while loop with Array.push was just as bad.

Re:The DOM isn't slow by iwillreply on Tuesday March 19, 2013 @11:12AM (#5401343)
Interesting, I very briefly deliberated while vs for, and how the performance of both had changed since last look.

But checking at: https://blogs.oracle.com/greimer/resource/loop-test.html

Still seemed to demonstrate a decreasing while loop as the fastest in my test.