Alfa Jango Blog Engineering, Software, and Entrepreneurship

Posts Tagged ‘Javascript’

Is Your Site Too Slow?
(The Importance of Page Load Speed)

Friday, May 14th, 2010

This is article #1 of a 4-part series. This article (along with Article #2) serves as a primer for the last two entries in this series, which discuss the most efficient way to put these concepts into practice in your web application. For more a more in-depth look at these concepts, see Yahoo!’s Best Practices for Speeding Up Your Web Site and Google’s Speed Tracer tutorial

Page load speed is becoming increasingly important as rich web applications become more interactive. It’s not just about usability anymore; it can now directly affect your placement in search engine results, now that Google uses page load speed in their ranking algorithm. Are you ready for a reality check? Get Google Webmaster Tools for your site, and go to the Labs >> Site Performance to view your average page load time, as seen by Google’s web crawlers. That’s right, Google is already tracking your site’s performance history.

Google Webmaster Tools is even kind enough to tell you how you stack up against the rest of the web. Here is what Webmaster Tools had to say about one of our sites before optimizing it for quick page loading:

On average, pages in your site take 4.5 seconds to load (updated on Feb 21, 2010). This is slower than 70% of sites. These estimates are of low accuracy (fewer than 100 data points). The chart below shows how your site’s average page load time has changed over the last few months. For your reference, it also shows the 20th percentile value across all sites, separating slow and fast load times.

Ouch. Did I mention this would be a painful reality check?

Now to be fair, there’s a very reasonable explanation for this. Google claims that the majority of users will click “back” to the search results page if a link takes too long to load. So, if a webpage is too slow for the visitor to read it, the relevance of the content is…well, irrelevant. I should point out, however, that it’s unknown precisely how much page load speed affects your placement in search results.

What is Included in Page Load Time?

At first, you may think that Google crawlers only index the initial load-time of the HTML. You’d be wrong. They actually include the time it takes to load all Javascript files, CSS stylesheets, images, etc. Now it’s time to see how your site performs. For this, you’ll need either the Page Speed extension for Firefox, or for an even better look into your site’s performance, get Speed Tracer for Chrome. And of course, there’s always the ever-popular YSlow extension for Firefox from Yahoo!

Watch Your Assets

Your website’s assets include all of the files the visitor’s browser must download to render your webpage. This includes Javascript files, CSS stylesheets, and images. And according you Yahoo!:

80-90% of the end-user response time is spent downloading all the components in the page: images, stylesheets, scripts, Flash, etc.

Continue to Article #2, which focuses on reducing the time it takes visitors to download your site’s assets by up to 90%. That means your site will load up to 2-3x faster.

New Release: jQuery EasyTabs Plugin

Friday, April 30th, 2010

I recently wrote a lightweight jQuery plugin called EasyTabs, and it is now released on the official jQuery plugin website. Most front-end developers are familiar with the jQuery-UI tab plugin. However, it is a very magical plugin with a complex structure, which completely styles your tabs for you, and limits your options when deciding how to structure the tabbed content.

For instance, it is very difficult to place your tabs below the tabbed content with jQuery-UI tabs.. You must perform some crazy CSS trickery, because jQuery-UI tabs forces you to place your <ul> before your content <div>s. Not to mention all of the jQuery-UI styling it does to your tabs by default, making it difficult to override and apply custom stylization to your tabs.

This new plugin, jQuery EasyTabs, is very flexible for the required markup and structure of your tabs and content. Also, it handles only the functionality of creating in-page tabs, leaving all of the styling up to you and your own CSS.

To check it out, see our documentation and demos. Then when you’re ready, you can download it from the jQuery plugins website.




Entries (RSS) and Comments (RSS)