3 ms·
Browser makers, including Apple, always say to use feature detection - i.e. to use features when they appear to be available. The alternative is user-agent snif
by AshleysBrain 4y ago
Browser makers, including Apple, always say to use feature detection - i.e. to use features when they appear to be available. The alternative is user-agent sniffing, which they advise against.
- kevincox 4y agoYeah, this is the problem with feature detection which isn't talked about enough. It is often easy enough to detect whole APIs or even some new methods but correct functionality and optional parameters can be hard or impossible to test. In most cases I have found that feature detection + a blacklist of problematic browsers is often a good compromise. But there is no perfect solution.