As announced at MIX last week, we’ve started shipping previews of IE10 (download) – just like we did through the IE9 alpha/beta stages. And this shows our continued focus on making IE a top browser choice for Windows users and IT shops. But, after reading Tony Ross’ post on the new IE10 user agent string, I wanted to forward along his post and emphasize a potential support issue.
Recently, my teammate Taylor Cowan found that one of our customer’s sites was incorrectly sniffing for the browser type and version. The code had a wrong RegEx string, which was yesterday’s problem. It also was checking for the IE version, looking for 1 digit – which is tomorrow’s problem. Someday, they’re going to think they found IE v1, when a IE10 user visits their site. That day is not that far off, with folks playing with platform previews and the release coming someday.
So, again, we recommend moving your code away from browser detection and towards “feature detection”. There are very few cases where sniffing is the mature coding practice, so start today enhancing your code.