r/programming • • Dec 20 '10

A Christmas Tree in 1k of Javascript

http://www.romancortes.com/blog/how-i-did-the-1kb-christmas-tree/
1.1k Upvotes

221 comments sorted by

View all comments

-4

u/rjcarr Dec 20 '10

A small niggle:

"and works slow in any current browser except in Chrome"

Why does everyone forget about safari? It worked great for me in safari on a laptop. Do people forget that Apple created Canvas and WebKit, both of which Chrome uses?

5

u/[deleted] Dec 21 '10

They forgot about Opera too. It works great in Opera.

1

u/[deleted] Dec 21 '10

It's a bit jerky for me in Opera on Linux. It's Opera 10, though.

1

u/jchrome Dec 20 '10

Safari and Chrome do share the (fantastic) Webkit rendering engine (so they both can enjoy the latest HTML 5 and CSS3 stuff), but they do not share the same JavaScript engines. Chrome's JS engine was developed by Google and is far superior to what anyone else has come up with yet. This particular demo is all about JS performance, which FYI is probably why several people down-voted you for your comment.

2

u/rjcarr Dec 20 '10

But it's JS mostly dealing with canvas. If google writes their own implementation of canvas then you'd have a point, but I'm pretty sure they don't.

2

u/ImTheGuyWithTheGun Dec 20 '10

While I don't think you should be downvoted, I also think Safari's success might be limited to Macs. On my fairly-capable Win7 system, Safari5 performs terribly on this demo. Then again, I find Safari on PCs to be sluggish in general. I'm sure it is a different story on a Mac...

1

u/[deleted] Dec 21 '10

Safari for Windows pretty much sucks, it's true. It's nothing like the OS X version.

→ More replies (1)