Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions cordova-common/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ Expoeses shared functionality used by [cordova-lib](https://github.com/apache/co
Represents special instance of NodeJS EventEmitter which is intended to be used to post events to cordova-lib and cordova-cli

Usage:
```
```js
var events = require('cordova-common').events;
events.emit('warn', 'Some warning message')
```
Expand All @@ -41,7 +41,7 @@ An error class used by Cordova to throw cordova-specific errors. The CordovaErro

Usage:

```
```js
var CordovaError = require('cordova-common').CordovaError;
throw new CordovaError('Some error message', SOME_ERR_CODE);
```
Expand All @@ -53,7 +53,7 @@ See [CordovaError](src/CordovaError/CordovaError.js) for supported error codes.
Exposes functionality to deal with cordova project `config.xml` files. For ConfigParser API reference check [ConfigParser Readme](src/ConfigParser/README.md).

Usage:
```
```js
var ConfigParser = require('cordova-common').ConfigParser;
var appConfig = new ConfigParser('path/to/cordova-app/config.xml');
console.log(appconfig.name() + ':' + appConfig.version());
Expand All @@ -64,7 +64,7 @@ console.log(appconfig.name() + ':' + appConfig.version());
`PluginInfo` is a wrapper for cordova plugins' `plugin.xml` files. This class may be instantiated directly or via `PluginInfoProvider`. The difference is that `PluginInfoProvider` caches `PluginInfo` instances based on plugin source directory.

Usage:
```
```js
var PluginInfo: require('cordova-common').PluginInfo;
var PluginInfoProvider: require('cordova-common').PluginInfoProvider;

Expand All @@ -80,7 +80,7 @@ console.log('The plugin ' + plugin1.id + ' has version ' + plugin1.version)
Utility module for dealing with sequential tasks. Provides a set of tasks that are needed to be done and reverts all tasks that are already completed if one of those tasks fail to complete. Used internally by cordova-lib and platform's plugin installation routines.

Usage:
```
```js
var ActionStack = require('cordova-common').ActionStack;
var stack = new ActionStack()

Expand All @@ -104,7 +104,7 @@ stack.process()
Module for spawning child processes with some advanced logic.

Usage:
```
```js
var superspawn = require('cordova-common').superspawn;
superspawn.spawn('adb', ['devices'])
.progress(function(data){
Expand All @@ -121,7 +121,7 @@ superspawn.spawn('adb', ['devices'])
A set of utility methods for dealing with xml files.

Usage:
```
```js
var xml = require('cordova-common').xmlHelpers;

var xmlDoc1 = xml.parseElementtreeSync('some/xml/file');
Expand Down