You are previewing Test-Driven JavaScript Development.

Test-Driven JavaScript Development

Cover of Test-Driven JavaScript Development by Christian Johansen Published by Addison-Wesley Professional

Chapter 10. Feature Detection

Aspiring JavaScript developers developing for the general web are faced with a rather unique challenge, in that very little is known about the environments in which scripts will execute. Even though we can use web analytics to gather information about our visitors, and external resources such as Yahoo’s graded browser support to guide us in decisions relevant to cross-browser development, we cannot fully trust these numbers; neither can they help make our scripts future proof.

Writing cross-browser JavaScript is challenging, and the number of available browsers is increasing. Old browsers see new version releases, the occasional new browser appears (the most recent noticeable one being Google Chrome), and new platforms ...

The best content for your career. Discover unlimited learning on demand for around $1/day.