Why should $.browser have to be deprecated?
I always see $.browser is deprecated and get asked to use $.supports instead. But they are different things. One gives you the browser version, the other gives you the supported features.
I have two major use cases for $.browser in my application:
- My organisation only tests the application against certain browser versions (e.g. IE8+, Safari 5.1+, etc) If someone has a lower version, we want to display a message saying that the application has not been fully tested against your browser version and you should upgrade your browser. In order to display this message we could use $.browser.
- Some javascript engines are faster than others. For example, one operation we found took about 15 seconds in both IE9 and IE10, it took more than three minutes to execute in IE8. Because of this, we want to disable some of the performance-intensive behaviour in IE8.
I don't think either of those things are possible using this $.supports. It seems strange that we have to use a deprecated method to achieve results which aren't available any other way.