Web Development

Reducing pageweight by compressing production css and js files

I’ve been a little obsessed with improving the speed of web pages via minified javascript and css files. YUI’s team not only agrees with this, they recommend gzipping your minified js and css files. For a while I’ve been calling YUI Compressor inside my push to production scripts to do the deed. However, with this new mention of gzipping, I think might be exploring other options such as the method mentioned on the page which originally linked me to that awesome YUI writeup; minifying and gzipping javascript and css on the fly using php.

Optimizing CSS selectors for load time; #home is faster than #menu li a#home

I was trying to figure out how to cut rendering time with smarter CSS. In my quest, I came across a plugin by google for Firebug called Page Speed which not only answered my question in the ‘Use efficient CSS selectors’ section (* #header #menu a:hover — Tag key with 2 descendant selectors and hover pseudo selector) but provided more details on the subject on the Page Speed Documentation.

“Descendant selectors are inefficient because, for each element that matches the key, the browser must also traverse up the DOM tree, evaluating every ancestor element until it finds a match or reaches the root element. The less specific the key, the greater the number of nodes that need to be evaluated.”

So, #home is faster than #menu li a#home; at least in Mozilla’s case. More on this here

Redmine for software project management

Back in 2008, I posted about the project management system, Project Pier, which was a fork of Active Collab. The system served my groups and I well for a while… but it was limited in different areas. Overall I thought it too slow and not so much tailored for software development as the new system I’m been using Redmine.

Redmine is a Ruby “clone” of the python based Trac system, which is also pretty good. I say clone because it’s really just influenced by I Trac, there goals were different than the Trac project. I decided on Redmine because it seemed to fit the bill for my group’s needs.

- It supported SVN and git browser integration.
- Per project wiki
- Per project user levels
- Issue tracking
- lightweight
- extendible (already some nice modules for download)

I haven’t had much hands on experience with Ruby but my buddy Dan Kinsley is a big advocate of RoR and after installing this, I can see why. The install was smooth and professional, largely done through the terminal. It went through without a hitch and immediately after logging into the newly setup system, I noticed how fast it was. This application makes good use of javascript and AJAX.

I was able to get SVN and git repos hooked in pretty quickly with specific projects and so far it’s been helping me manage tasks and layout projects better and faster than Project Pier.