Feature Detection vs Browser Detection
We’ve all heard time and time again that when you’re trying to determine the JavaScript capabilities of a browser you should avoid user agent string parsing like a horrible plague and instead put your trust in a little thing called feature detection. But why should we? What’s so bad about relying on user agent strings? Also, how do I even use feature detection anyway? Read on and you’ll find the answer to all of these questions.