Next Steps

Next Steps For developers who have an understanding of how to use the Cordova CLI and make use of plugins, there are a few things you may want to consider researching next to build better, more performant Cordova applications. The following document offers advice on various topics relating to best practices, testing, upgrades, and other topics, but is not meant to be prescriptive. Consider this your launching point for your growth as a Cordova developer. Also, if you see something that can be i

menubutton

menubutton The event fires when the user presses the menu button. Applying an event handler overrides the default menu button behavior. Quick Example document.addEventListener("menubutton", onMenuKeyDown, false); function onMenuKeyDown() { // Handle the back button }

iOS WebViews

iOS WebViews This guide shows how to embed a Cordova-enabled WebView component within a larger iOS application. For details on how these components can communicate with each other, see Application Plugins. Support for WebViews for iOS started with Cordova version 1.4, using a Cleaver component for which the Xcode template serves as a reference implementation. Cordova 2.0 and later versions only support the subproject-based Cleaver implementation. These instructions require at least Cordova 3.x

iOS Plugin Development

iOS Plugin Development Guide This section provides details for how to implement native plugin code on the iOS platform. Before reading this, see [Plugin Development Guide][plugin-dev] for an overview of the plugin's structure and its common JavaScript interface. This section continues to demonstrate the sample echo plugin that communicates from the Cordova webview to the native platform and back. An iOS plugin is implemented as an Objective-C class that extends the CDVPlugin class. For JavaScri

iOS Platform

iOS Platform Guide This guide shows how to set up your SDK development environment to deploy Cordova apps for iOS devices such as iPhone and iPad, and how to optionally use iOS-centered command-line tools in your development workflow. You need to install the SDK tools regardless of whether you want to use these platform-centered shell tools or cross-platform Cordova CLI for development. For a comparison of the two development paths, see the Overview. For details on the CLI, see Cordova CLI Refe

iOS Platform

iOS Platform Guide This guide shows how to set up your SDK development environment to deploy Cordova apps for iOS devices such as iPhone and iPad, and how to optionally use iOS-centered command-line tools in your development workflow. You need to install the SDK tools regardless of whether you want to use these platform-centered shell tools or cross-platform Cordova CLI for development. For a comparison of the two development paths, see the Overview. For details on the CLI, see Cordova CLI Refe

Hooks

Hooks Introduction Cordova Hooks represent special scripts which could be added by application and plugin developers or even by your own build system to customize cordova commands. Cordova hooks allow you to perform special activities around cordova commands. For example, you may have a custom tool that checks for code formatting in your javascript file. And, you would like to run this tool before every build. In such a case, you could use a 'before_build' hook and instruct the cordova run time

endcallbutton

endcallbutton This event fires when the user presses the end call button. The event overrides the default end call behavior. Quick Example document.addEventListener("endcallbutton", onEndCallKeyDown, false); function onEndCallKeyDown() { // Handle the end call button }

Embedding WebViews

Embedding WebViews Cordova applications are ordinarily implemented as a browser-based WebView within the native mobile platform. This section shows how, for supporting platforms, to create your own WebView components that make full use of Cordova APIs. You can then deploy these Cordova application components along with native components in a hybrid application. To deploy a WebView, you need to be familiar with each native programming environment. The following provides instructions for supporte

deviceready

deviceready The deviceready event fires when Cordova is fully loaded. This event is essential to any application. It signals that Cordova's device APIs have loaded and are ready to access. Cordova consists of two code bases: native and JavaScript. While the native code loads, a custom loading image displays. However, JavaScript only loads once the DOM loads. This means the web app may potentially call a Cordova JavaScript function before the corresponding native code becomes available. The devi