HTML and CSS Reference
Writing mobile web apps that span all platforms and all browsers can be a huge under‐
taking. Previously, web app developers didn't care if a desktop computer had a camera
or accelerometer attached to it. The web applications of yesterday were not tied to the
operating system and the capabilities of desktop hardware. Now, the Mobile Web adds
another dimension of support to the apps we build, and the fragmentation across
browsers and devices is mind-blowing. We must now create applications to be compat‐
ible across browsers, platforms, and devices. For example, Android's WebKit-based
browser supported Web Workers in version 2.1, but later disabled support in version
2.2, 3.0, and 4.0. Then, support of Web Workers was fixed and turned back on in 4.1!
Confusing, right? This is what I mean by another dimension of support or fragmenta‐
tion . You're not only supporting browsers, but the operating system the browser is tied
to as well.
How do you sort it all out? Not to worry, the remainder of the chapter examines the
various mobile browsers, discusses the commonly supported APIs of each device, and
identifies a core set of features from which you can build a solid enterprise mobile web
You can find the latest matrix of HTML5 support across all rendering
engines on the HTML5 engine comparison page on Wikipedia.
Mobile Web Browsers
Take a moment to review the various mobile browsers and their respective communities.
As developers, we must try to embrace all platforms and develop applications that span
all of the following browsers—and more if needed. For example, your users should not
be limited to a WebKit-only mobile application in which your code runs on iOS and
WebKit is the browser engine behind Mobile Safari, Android, and Chrome, to name a
few. This open source project is constantly pushing the open web envelope, adapting to
the latest W3C specifications as they're published. The recent explosion of interest in
WebKit can be attributed to the fact that it powers many of the leading mobile platform
Figure 2-1 shows the source code revision (vertical) as the function of time (horizontal).
Some icons are there to represent products associated with WebKit; the position ap‐
proximately resembles the era those products were made popular.