Your Website is Too Damn Big

According to HTTP Archive, websites are approaching an average of 2MB per page. That's nearly double the average from just two years ago. I have some ideas why and how you can fix it.

Aug 2012 vs. Aug 2014

Type20122014Change
HTML48K58K+21%
JavaScript217K295K+35%
CSS39K54K+38%
Images694K1176K+69%
Other *18K131K+627%
Total1,105K1,855K+68%

* Custom fonts and vector icons seem to be most of "Other"

But what's to blame?

The three bigges are:

  • Images: most likely due to retina displays, web developers are under more pressure than ever to keep the eye candy pretty at an additional average cost of nearly 500K per page since 2012.

  • Custom fonts & vector icons: also due to retina displays (and to a lesser extent mobile devices), these techniques (e.g. icoMoon and SVG glyphs) are super cool but

Continue...

Crazy idea: using custom HTML tag names for UI controls

Now that I have a break from my last job, I’ve been working feverishly on my new JavaScript app framework. Called Jo, one of the themes of the architecture is keeping the code simple by leveraging advanced CSS (finally) which is common among most modern browsers.

One of the issues I’ve run into with this approach in the past is the CSS gets thick with, basically, lots of div tags with classnames like “menubar” and “group”. I found this can make for some difficult maintenance, especially when working on cross-platform apps.

Worse, one of the first real apps I’m building with the new framework includes a searchable, indexed set of its own documentation. Cute thought, but hurdle one was: how the heck do I pull in HTML doc files with their interesting (and possibly themed) CSS without creating odd interference with my UI controls?

After some vexing

Continue...