Wednesday, August 05, 2009

Writing Faster Javascript

Lately, I am researching into creating faster Web Application
FrontEnds using Javascript. And there is one quote that
smiles me most. It goes like, Users of Web application dont
really care for how faster your application is designed
and implemented, they more care about how the application
gives the impression of Speed. This is a great statement.
It all boils down to a great idiom in designing faster
and performance driven applications on Web. If you cannot
fasten or optimize a particular part of the application,
just make it look or behave like its fast. And it works too.
This apart, I also happened to watch Nicholas C. Zakas
talk on creating Faster Javascript Apps.
The whole talk sums up into the following points to consider
while debating on how to increase the performance of Javascript.

1. Minimize Global Variables Lookup
2. Cache the Global Lookup into Local variables
3. With Statement is bad
4. Minimize DOM Manipulations
5. Use DocumentFragment to reduce Reflow.
6. Minimize Object Property lookups
7. Cache Array Lookups

More on the above topics in my next posts.

No comments:

Post a Comment