Skip to Content
Test-Driven JavaScript Development
book

Test-Driven JavaScript Development

by Ravi Kumar Gupta
December 2015
Intermediate to advanced
240 pages
4h 57m
English
Packt Publishing
Content preview from Test-Driven JavaScript Development

Browser detection

An ideal way to develop a system is to perform capability testing first. We should get the information if the environment where the system will run is capable of doing things we want to do. But that hardly happens, and at the same time it is not always possible, be it any reason—unforeseen issues, changing requirements, insufficient time, and many more. That's one big reason we need browser detection and perform quick fixes.

User agent sniffing

Browser detection is mostly done by checking user agent string, which is not completely reliable because user agent string can be spoofed. A developer is encouraged to use feature detection over browser detection. You should not rely on browser detection to assume that a feature will be ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Test-Driven JavaScript Development

Test-Driven JavaScript Development

Christian Johansen
Front-End Development Projects with Vue.js

Front-End Development Projects with Vue.js

Raymond Camden, Hugo Di Francesco, Clifford Gurney, Philip Kirkbride, Maya Shavin, Dániel Szabó

Publisher Resources

ISBN: 9781782174929Supplemental Content