We all know how important speed is when comes to websites. But over the past couple of years I have noticed a disturbing trend. Due to how we are all trying to create multi-platform websites, web developers are turning to ready-built frameworks and templates.
The problem is that while these frameworks do make it easier (and faster) to code, you are only using a fraction of the code. The result is bloatware
in which your site ends up being terribly slow.
And I see this with so many sites. Look at the example below. It a page speed test from one our our national newspapers, loading just one page (this one: http://goo.gl/m9xurD
The page itself is nothing special. Sure, it contains a lot of images and links, just like any other page on a newspaper site, but there is no super fancy interactivity. It's very basic stuff.
The result of this is that the page loads rather slow, of which 69% is due to the scripts alone. The total size of the scripts are 0.7 MB + another 0.6 MB for other elements that couldn't be identified.
And, of the total size of the page (which is a staggering 2.2MB) more than half is coming from non-page sources.
To put into perspective just how much code this page is including, think of it like this:
The article itself is 2,072 characters / 328 words long
I see this problem on so many sites. Web designers have become lazy (or too busy). Instead of thinking about what frameworks they use, they just keep adding them. And of those frameworks added, they often only use 1% of what the code is designed to do. Often most of the functionality is only needed on a very few pages but are included on every single page.