Pages

Wednesday, April 18, 2012

Tighter Code For A Greener Planet

Ever noticed how some websites take longer to display the page than others? Ever blamed it on bloat in the page? Now an interesting experiment has been reported that they not only take longer to load, they use more energy, draining your battery faster.

New Scientist reports "Wikipedia uses a custom file Javascript along with a generic library to collapse and expand the various sections on a page, but much of the library goes unused. By rewriting the site's Javascript to just perform the required function, [researchers] were able to reduce the energy used from 15 to 9.5 Joules.

Making similar changes to the CSS files and images, they were able to reduce the total energy used in loading Wikipedia from 35 to 25 Joules, a saving of 29 per cent.

Over the life of an average portable phone it must download several thousand to tens of thousands of pages. Lets' encourage tighter code for a greener planet.

No comments:

 


[get this widget]