Here is another reason Flash is better than AJAX for web apps
February 5th, 2009 | Published in Uncategorized | 4 Comments
AppleInsider | IE8′s JavaScript performance lags well behind Safari, Chrome
Above is a recent article on the JavaScript performance of the next-generation web browsers/rendering engines, including IE8, Firefox 3.1, Webkit r40220, Chrome 2.0.158.0 and Opera 10.
From the test result in the article, we can see that the performance of JS varies a lot across the browsers (up to 1:10). This make developing cross-platform web apps using AJAX much more difficult since you need to make it as lightweight as possible.
Developing in Flash would not face this problem because swf content runs inside the virtual machine. Although it has been claimed that Flash content runs relatively slower under Mac, but the different is not noticeable in most cases. And the preformance of ActionScript (3) is A LOT higher than JavaScript in any browser.
When developing large scale CPU hungry web apps, you better use Flash instead of AJAX. (for other stuff, AJAX may be better, or a lot better…)
PS. I’ve googled around for some benchmarks on AS/JS to prove my point, but seems that there is no recent benchmark that aims for this (only a 2007 one). Hopefully I will have time to do it by myself in this week.
February 6th, 2009 at 7:12 pm (#)
Interesting points.
From my experience, CPU intensive flash content often runs significantly slower on a Mac, in our office anyway.
I’ll be keen to see the benchmark stats when you get them done.
February 6th, 2009 at 10:44 pm (#)
is a spoon better than a fork ?
February 7th, 2009 at 3:12 am (#)
@Lawrie
I will test on both Windows and Mac, only Linux unfortunately I do not have a computer that installed it natively.
I have quite a lot of homeworks in queue, so please wait.
@_s
Totally agree your point.
Flash for the computational intensive stuff and AJAX for the simple interactive stuff.
February 8th, 2009 at 9:33 am (#)
If AJAX is properly achieved, with a scalable design, it can be just as good as Flash.
You can’t compile AJAX, so more runtime errors are likely as you debug.
Both languages have debugging techniques that allow you to step through code (AJAX has alerts), so they are pretty even there.
Flash runs in Flash player, so I agree that cross-browser performance and compatibility is a major failure of AJAX.
AJAX allows for better SEO, but that will change.
I have to say that imo it’s a tie. There’s a greater backlash against Flash by programmers who resent the ubiquity of creative platforms. This is important to consider when you listen to the rhetoric surrounding this subject.