Kurt McKee

lessons learned in production

Archive

Hey there! This article was written in 2012.

It might not have aged well for any number of reasons, so keep that in mind when reading (or clicking outgoing links!).

Customizing websites using a scalpel

Posted 24 April 2012 in extension and firefox

My computer is absurdly old. I hand-selected the components and assembled it back in 2002. It was a marvel of processing power at the time, but you'd never know it now. As software has become more featureful, my computer has proven unable to keep up. Nowadays some websites cause Firefox to hang for seconds at a time. As an example, two weeks ago I had reason to visit SoundCloud.com.

One of my brothers was in town, and we had stopped at Jimmy John's for lunch, but what's this? They had some absolutely bangin' music on! I asked the guy behind the counter about it, and he grinned and said "This is Unprotected Sex." While I silently congratulated myself on my word choice, he continued that it was his and his friend's music, and that I could check it out on SoundCloud. (The track in question was "Wizardsbro demo".)

SoundCloud's music player has an interesting feature: users can leave comments at specific moments in the song, and the website will put their avatar underneath the player at the point that they left the comment. For popular artists like Porter Robinson or Skrillex, this means that there are hundreds upon hundreds of overlapping images to load, and my computer can't handle that.

I finally fixed the problem using the Element Hiding Helper extension, a companion to Adblock Plus. It let me quickly zero in on the offending HTML and block it forever:

soundcloud.com##OL.timestamped-comments:last-child

I've again extended the life of my computer, so while I'm an idiot for doing so, at least...um...

Well, the point is that Element Hiding Helper is awesome, and you should use it to excise the stupid stuff websites throw at you.

☕ Like my work? I accept tips!