Ten Tips for enhancing your Page Response Time

1. Do not declare your JavaScript functions in your view (JSP, XHTML, …etc). Instead, externalize your JavaScript functions to an external JavaScript file because JavaScript files are cached on the browser level.
2. Compress the JavaScript files.
3. Reduce the JavaScript code on the page load.
4. Do not use more than one client framework (for example: Dojo and YUI) on the same page.
5. Avoid duplicate JavaScript files include.
6. Avoid duplicate JavaScript functions.
7. Do not define your styles in your view. Instead, externalize your CSS code to a CSS file because CSS files are cached on the browser level.
8. Compress the CSS files.
9. Collect the images into one big image, and use the background-position for extracting the desired image.
10. Use Ajax for page updates like loading lists and independent lists.

This entry was posted in Performance, Web 2.0 by hazems. Bookmark the permalink.

About hazems

Hazem Saleh has more than eleven years of experience in Cloud, Mobile and Open Source technologies. He worked as a software engineer, technical leader, application architect, and technical consultant for many clients around the world. He is an Apache PMC (Project Management Committee) member and a person who spent many years of his life writing open source software. Beside being the author of the "JavaScript Unit Testing" book, "JavaScript Mobile Application Development" book, "Pro JSF and HTML5" book and the co-author of the "Definitive guide to Apache MyFaces" book, Hazem is also an author of many technical articles, a developerWorks contributing author and a technical speaker in both local and international conferences such as ApacheCon North America, Geecon, JavaLand, JSFDays, CON-FESS Vienna and JavaOne. Hazem is an XIBMer, he worked in IBM for ten years. Now, He is working for Nickelodeon New York as a Mobile Architect. He is also an OpenGroup Master Certified Specialist.