This is a starter project template to build rich hybrid native/web applications with Apache Cordova using Node.js. This skeleton is aimed at leveraging packages to develop and build, while providing a set of unified tasks and definitions to focus less on configuration and setup.
This starter project builds on top of core packages and utilities. Visit this page for more information on core functionality.
Additional tasks are included for working with Cordova. Visit this page for more information on tasks.
These commands add additional features/items to the project that are not included by default. If you're working with a web framework some of these may not be available.
add:fastclickrem:fastclickAdd/remove FastClick to/from the project for optimized click events in touch devices.
add:hammeradd:hammerjqueryrem:hammerAdd/remove Hammer.js (standalone or jQuery plugin) to/from the project for touch event handling.
add:devicejsrem:devicejsAdd/remove device.js to handle different device options in CSS and JavaScript. NOTE: by default the project is configured so if device.js is used, it is accessed using the devicejs variable. This is to avoid conflict with Cordova's device variable.
These set of tasks are to set up and initialize Cordova projects to wrap your application as a native application. device denotes the application device to target. (currently supports ios and android) The Cordova project is created in the cordova directory. The workflow copies assets to cordova/www.
cordova:init package=io.cordova.hellocordova name=HelloCordovaGenerate a new Cordova project using cordova-cli.
package and name parameters are optional, which falls back to the default Cordova options. If you specify name, you must also specify package.cordova:lsList device platforms and plugins the Cordova project currently supports.
cordova:add device=[device]cordova:rem device=[device]Add/remove specified device support to/from the Cordova project.
cordova:add plugin=[plugin]cordova:rem plugin=[plugin]Add/remove a plugin to/from the Cordova project.
cordova:update device=[device]Update specified device platform. This is useful when you update Cordova and as a result requires updating specific platform features.
Additional tasks/parameters are included to support packaging Cordova projects into native applications.
build:[mode] device=[device]If you include the device parameter then instead of just assembling code and assets, they are trasfered over to the Cordova project and a native application package is built. (ex: jake build:prod device=ios)
emulate:[mode] device=[device]Assemble code and assets, build a native application with Cordova, and deploy to an emulator for the specified device. NOTE: ios-sim is required to start the iOS simulator on OS X.