Feature-Sniffing Rather Than Browser-Sniffing

I’ve linked to Modernizr before, but it’s worth a re-link in light of Apple’s Safari-only “HTML5” demos. Rather than sniffing for specific browsers, they’d have been better served sniffing for specific browser features on a per-demo basis. I don’t have a problem with the fact that some of their demos take advantage of Safari-only features — why not show off Safari’s leading edge capabilities? But it’s wrong that a site promoting “standards” blocks browsers that are capable of rendering certain of the demos.

I.e., instead of “Use Safari to view these demos”, the site could serve as a “Safari can render all of these demos, see which ones work in your browser” example.

See also: “Mark Pilgrim’s All-in-One Almost Alphabetical No-Bullshit Guide to Detecting Everything”.

Friday, 4 June 2010