Detection

When I wrote about responsible responsive images a few months back, I outlined my two golden rules when evaluating the various techniques out there:

  1. The small image should be default.
  2. Don’t load images twice (in other words, don’t load the small images and the larger images).

I also described why that led to my dissatisfaction with most server-side device libraries for user-agent sniffing:

When you consider the way that I’m approaching responsive images, those libraries are over-engineered. They contain a massive list of mobile user-agent strings that I’ll never need. Remember, I’m taking a mobile-first approach and assuming a mobile browser by default. So if I’m going to overturn that assumption, all I need is a list of desktop user-agent strings.

I finished by asking:

Anybody fancy putting it together?

Well, it turns out that Brett Jankord is doing just that with a device-detection script called Categorizr:

Instead of assuming the device is a desktop, and detecting mobile and tablet device user agents, Categorizr is a mobile first based device detection. It assumes the device is mobile and sets up checks to see if it’s a desktop or tablet. Desktops are fairly easy to detect, the user agents are known, and are not changing anytime soon.

It isn’t ready for public consumption yet and there are plenty of known issues to iron out first, but I think the fundamental approach is spot-on:

By assuming devices are mobile from the beginning, Categorizr aims to be more future friendly. When new phones come out, you don’t need to worry if their new user agent is in your device detection script since devices are assumed mobile from the start.

Have you published a response to this? :

Related links

LukeW | Which One: Responsive Design, Device Experiences, or RESS?

Luke outlines three different solutions to delivering a site to multiple devices.

Tagged with

Brett Jankord – Active development on Categorizr has come to an end

I think it’s a bit of a shame that Brett is canning his mobile-first device-detection library, but I totally understand (and agree with) his reasons.

There is a consensual hallucination in the market, that we can silo devices into set categories like mobile, tablet, and desktop, yet the reality is drawing these lines in the sand is not an easy task.

Tagged with

Previously on this day

15 years ago I wrote The iPad and the web

I, for one, welcome our non-hackable ubicomp devices.

18 years ago I wrote The Web 2.0 show

Take the test.

18 years ago I wrote The tyranny of mouseover

Those bloody previews need to die a snappy death.

22 years ago I wrote Trout Thursday

Today’s the day to eat some trout.

23 years ago I wrote Macromedia gets mean

Oh, dear. I know that it’s a dog-eat-dog world in the WYSIWYG HTML editor market, but Macromedia have just upped the ante.

23 years ago I wrote PixelNhance

There’s a very neat little piece of software for Mac OS X called PixelNhance.

23 years ago I wrote Miniputt

This is even better than the real thing: a game of mini-golf in Flash.