Browser engine components and technology support

The browser engine includes components such as native and JavaScript plugins, and supports technologies such as the HTML5 application framework, CSS, and standard APIs.

HTML5 apps

The HTML5 application framework provides the additions the browser engine needs to support full-fledged apps. This environment allows you to create and deploy apps built from web technologies (HTML5, CSS3, and JavaScript) with plugins that provide access to the underlying device hardware and native services, just like native C/C++ apps.

Native plugins

The browser engine includes, through a dynamically-linked library, plugins based on the Netscape Plugin API (NPAPI). These native plugins provide access to PPS (Persistent Publish/Subscribe), SQL, and Screen services. You can add more plugins as required. For example, you can add the native SQLite 3 plugin, which provides SQLite database access, including a complete API for opening, querying, and modifying a database.

JavaScript plugins

JavaScript Cordova plugins use the browser engine plugins to provide HTML5 apps with access to middleware-layer services. The reference image for the SDK for Apps and Media includes the browser and power plugins. For example, the Browser Lite app uses the browser plugin to build a simple web browser.

Web Inspector tool

Included as part of WebKit , Web Inspector is a useful debugging and profiling development tool for web content. You can use this tool to troubleshoot and optimize your web content for your apps. The tool includes features and capabilities such as inspection, profiling, and console integration. For details, see "Debugging Web Apps" in this guide.

CSS support

The browser engine supports CSS3 properties. You can modify CSS files to customize the appearance of your app. Consider using Sass and Compass to help you customize CSS files. For a complete list of supported CSS3 properties for WebKit-based browsers, see the CSS3 Browser Support Reference at the following W3Schools site:

HTML5 elements

The HTML5 SDK supports the use of HTML5 elements in your apps. The table below describes some of the more common elements used to develop HTML5 apps. For more information about these elements, see the corresonding W3Schools references:

Element Description
HTML5 Audio Represents a sound or audio stream.
HTML5 Canvas Provides a container for JavaScript to draw graphics on a webpage.
HTML5 Geolocation Scripts use this object to programmatically determine the location information associated with the hosting device.
HTML5 Web Storage (localStorage) Provides functions to access a list of key/value pairs for local storage objects (i.e., objects that persist after a browser session has ended).
HTML5 Web Storage (sessionStorage) Lets you save a large amount of key/value pairs and text for session storage objects (i.e., objects that are valid only for the current browser session).
HTML5 Video Represents a video or video stream.
HTML5 Web Workers Allows JavaScript code to be executed in a background thread.

Browser API and offline support

HTML5 includes several features that address the challenge of building web apps that work offline. These features include SQL, offline app-caching APIs, online/offline events, status, and the localStorage API. For more information about creating web apps that work offline, see the W3C document Offline Web Applications.

The browser engine supports various standard APIs. For information about these APIs, see the following W3C resources:

API Support Description
Web SQL Database A set of APIs for manipulating client-side databases using SQL.
WebSocket API An API that allows webpages to use the WebSocket protocol. This protocol enables web apps to maintain bi-directional communications with a remote host.
Web Workers An API that allows authors of web apps to spawn background workers running scripts in parallel to their main page. This process allows for thread-like operation with message passing as the coordination mechanism.
Geolocation API Specification An API that provides scripted access to geographical location information associated with the hosting device.