### Install Dependencies and Clone Repositories Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/lodash/release.md Installs npm dependencies, clones the lodash and lodash-cli repositories, and sets up the lodash-cli within the project's node_modules. This prepares the environment for building lodash. ```sh npm run build npm run doc npm i git clone --depth=10 --branch=master git@github.com:lodash-archive/lodash-cli.git ./node_modules/lodash-cli mkdir -p ./node_modules/lodash-cli/node_modules/lodash; cd $_; cp ../../../../lodash.js ./lodash.js; cp ../../../../package.json ./package.json cd ../../; npm i --production; cd ../.. cp lodash.js npm-package/lodash.js cp dist/lodash.min.js npm-package/lodash.min.js cp LICENSE npm-package/LICENSE ``` ```sh git clone https://github.com/lodash/lodash.git git clone https://github.com/bnjmnt4n/lodash-cli.git ``` -------------------------------- ### Install p-try using npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/p-try/readme.md This snippet shows the command to install the p-try package using npm, the Node Package Manager. This is a prerequisite for using the p-try module in your project. ```bash npm install p-try ``` -------------------------------- ### Node.js Installation and Usage of BigInteger.js Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/big-integer/README.md This example demonstrates how to install and require the BigInteger.js library in a Node.js environment. It uses npm for installation and the require function to import the library. ```bash npm install big-integer ``` ```javascript var bigInt = require("big-integer"); ``` -------------------------------- ### Install Cordova Camera Plugin Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/plugins/cordova-plugin-camera/README.md Provides commands for installing the cordova-plugin-camera. It includes instructions for modern Cordova versions (5.0+), deprecated IDs for older versions, and direct installation from a Git repository URL for unstable builds. These commands are executed in a command-line interface. ```bash cordova plugin add cordova-plugin-camera ``` ```bash cordova plugin add org.apache.cordova.camera ``` ```bash cordova plugin add https://github.com/apache/cordova-plugin-camera.git ``` -------------------------------- ### Install openid-client using npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/openid-client/README.md Installs the openid-client library using npm. This command is for Node.js environments and requires npm to be installed. ```console npm install openid-client ``` -------------------------------- ### Install Picomatch with npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/picomatch/README.md This snippet shows how to install the picomatch library using npm. It is a standard command-line instruction for package installation. ```sh npm install --save picomatch ``` -------------------------------- ### Install simple-concat using npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/simple-concat/README.md This command installs the simple-concat package from npm. Ensure you have Node.js and npm installed on your system. ```bash npm install simple-concat ``` -------------------------------- ### Install verb and generator for building docs Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/is-extglob/README.md This command installs 'verb' and 'verb-generate-readme' globally, which are tools used to build the project's documentation. After installation, 'verb' can be run to generate the README file. ```sh npm install -g verb verb-generate-readme && verb ``` -------------------------------- ### Install Node.js Glob Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/glob/README.md Install the glob library using npm. This is the first step before using glob in your Node.js project. ```bash npm i glob ``` -------------------------------- ### Install @nodelib/fs.scandir using npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/@nodelib/fs.scandir/README.md This command installs the @nodelib/fs.scandir package using npm. Ensure you have Node.js and npm installed on your system. ```console npm install @nodelib/fs.scandir ``` -------------------------------- ### Install dash-ast via npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/dash-ast/README.md This command installs the dash-ast package and its dependencies using npm. Ensure you have Node.js and npm installed on your system. ```bash npm install dash-ast ``` -------------------------------- ### Install Whitelist Plugin (Bash) Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/cordova-plugin-whitelist/README.md Commands to install the cordova-plugin-whitelist using the Cordova CLI and npm. This includes adding the plugin and preparing the project for the changes. ```bash $cordova plugin add cordova-plugin-whitelist $cordova prepare ``` -------------------------------- ### Camera API Examples Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/plugins/cordova-plugin-camera/doc/fr/index.md Examples demonstrating how to take a photo and retrieve it as a base64-encoded string or a file URI. ```APIDOC ## Taking a Photo and Retrieving as Base64 ### Description Takes a photo using the device's camera and returns the image data as a base64-encoded string. ### Method `navigator.camera.getPicture` ### Parameters - **onSuccess** (function) - Callback function that receives the base64 image data. - **onFail** (function) - Callback function that is called if the operation fails, receiving an error message. - **options** (object) - Optional configuration object. - **quality** (number) - Quality of the saved image (0-100). Default is 50. - **destinationType** (number) - Desired format of the return value. `Camera.DestinationType.DATA_URL` (0) for base64. ### Request Example ```javascript navigator.camera.getPicture(onSuccess, onFail, { quality: 50, destinationType: Camera.DestinationType.DATA_URL }); function onSuccess(imageData) { var image = document.getElementById('myImage'); image.src = "data:image/jpeg;base64," + imageData; } function onFail(message) { alert('Failed because: ' + message); } ``` ## Taking a Photo and Retrieving File URI ### Description Takes a photo using the device's camera and returns the file URI of the saved image. ### Method `navigator.camera.getPicture` ### Parameters - **onSuccess** (function) - Callback function that receives the image file URI. - **onFail** (function) - Callback function that is called if the operation fails, receiving an error message. - **options** (object) - Optional configuration object. - **quality** (number) - Quality of the saved image (0-100). Default is 50. - **destinationType** (number) - Desired format of the return value. `Camera.DestinationType.FILE_URI` (1) for file URI. ### Request Example ```javascript navigator.camera.getPicture(onSuccess, onFail, { quality: 50, destinationType: Camera.DestinationType.FILE_URI }); function onSuccess(imageURI) { var image = document.getElementById('myImage'); image.src = imageURI; } function onFail(message) { alert('Failed because: ' + message); } ``` ``` -------------------------------- ### Install acorn-node Package Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/acorn-node/README.md Installs the acorn-node package using npm. This is the first step to integrate acorn-node into your project. ```bash npm install acorn-node ``` -------------------------------- ### Install Camera Plugin Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/plugins/cordova-plugin-camera/doc/ja/README.md This command installs the cordova-plugin-camera using the Cordova CLI. It adds the necessary native and JavaScript files to the project. ```bash cordova plugin add cordova-plugin-camera ``` -------------------------------- ### Cordova Installation Command Line Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/readme.md Installs the Cordova command-line interface globally using npm. This command ensures that the `cordova` command is available system-wide for managing Cordova projects. ```bash npm install -g cordova ``` -------------------------------- ### Browser HTTP GET Request Example Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/stream-http/README.md Demonstrates how to perform an HTTP GET request in a browser environment using a JavaScript library, handling response data and end events. This snippet is specific to browser JavaScript execution. ```javascript http.get('/bundle.js', function (res) { var div = document.getElementById('result'); div.innerHTML += 'GET /beep
'; res.on('data', function (buf) { div.innerHTML += buf; }); res.on('end', function () { div.innerHTML += '
__END__'; }); }) ``` -------------------------------- ### Install bplist-parser via npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/bplist-parser/README.md This command installs the bplist-parser package from the npm registry. It is a prerequisite for using the library in your Node.js project. ```bash $ npm install bplist-parser ``` -------------------------------- ### Install Node.js Dependencies for Cordova.js Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/cordova-js/README.md Installs all necessary Node.js dependencies for building Cordova.js. Requires Node.js and npm to be installed. ```bash npm install ``` -------------------------------- ### Install safe-buffer Package Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/safe-buffer/README.md This snippet shows how to install the 'safe-buffer' package using npm. It is a prerequisite for using the package's functionalities. ```bash npm install safe-buffer ``` -------------------------------- ### iOS Camera Plugin Installation Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/plugins/cordova-plugin-camera/README.md Instructions for installing the camera plugin on iOS, including required usage descriptions. ```APIDOC ## iOS Camera Plugin Installation Since iOS 10, it's mandatory to add `NSCameraUsageDescription` and `NSPhotoLibraryUsageDescription` to your app's `info.plist` file. - `NSCameraUsageDescription`: Describes the reason the app accesses the user’s camera. - `NSPhotoLibraryUsageDescription`: Describes the reason the app accesses the user's photo library. These strings are displayed to the user when the system prompts for permission. **Installation Example with Usage Descriptions:** ```bash cordova plugin add cordova-plugin-camera --variable CAMERA_USAGE_DESCRIPTION="your usage message" --variable PHOTOLIBRARY_USAGE_DESCRIPTION="your usage message" ``` If these variables are not provided during installation, the plugin will add an empty string as the value for these keys. ``` -------------------------------- ### Installation with npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/constants-browserify/README.md Provides the command to install the constants-browserify package using npm, the Node Package Manager. This is a prerequisite for using the module in your project. ```bash npm install constants-browserify ``` -------------------------------- ### Browser Installation and Usage of object-hash (JavaScript) Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/object-hash/readme.markdown Provides instructions and a code example for using the object-hash library in a browser environment. It involves including the library via a script tag and then utilizing its functions, such as `objectHash.sha1`. ```html ``` -------------------------------- ### Install buffer-from using npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/buffer-from/readme.md This command installs the 'buffer-from' package as a dependency for your project. ```sh npm install --save buffer-from ``` -------------------------------- ### Install Whitelist Plugin (Bash) Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/plugins/cordova-plugin-whitelist/README.md Commands to install the cordova-plugin-whitelist using the Cordova CLI and npm. After installation, `cordova prepare` is used to apply the changes to the project. ```bash $ cordova plugin add cordova-plugin-whitelist $cordova prepare ``` -------------------------------- ### Install pify Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/pify/readme.md Install the pify package using npm. This is the first step to using pify in your Node.js project. ```bash npm install pify ``` -------------------------------- ### Install fast-json-parse Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/fast-json-parse/README.md Installs the fast-json-parse module using npm. This command adds the package as a dependency to your project. ```bash npm i fast-json-parse --save ``` -------------------------------- ### Install @nodelib/fs.walk Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/@nodelib/fs.walk/README.md Installs the @nodelib/fs.walk package using npm. This is the initial step to integrate the directory traversal functionality into your Node.js project. ```console npm install @nodelib/fs.walk ``` -------------------------------- ### Install Punycode.js via Bower Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/url/node_modules/punycode/README.md This command installs the Punycode.js library using Bower, a front-end package manager. It's suitable for browser-based projects. ```bash bower install punycode ``` -------------------------------- ### module-deps npm Installation Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/module-deps/readme.markdown Provides npm commands for installing the module-deps package locally for project use and globally for command-line access. ```bash npm install module-deps npm install -g module-deps ``` -------------------------------- ### Install Universalify with npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/universalify/README.md This command installs the universalify package using npm. It's a prerequisite for using the library in your Node.js project. ```bash npm install universalify ``` -------------------------------- ### Install lodash.memoize using npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/lodash.memoize/README.md These commands demonstrate how to install the lodash.memoize package globally and as a dependency for a project using npm. ```bash npm i -g npm npm i --save lodash.memoize ``` -------------------------------- ### Cordova Plugin Installation Command (Shell) Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/plugins/cordova-plugin-ble-peripheral/README.md This command installs the BLE Peripheral plugin directly from its GitHub repository using the Cordova CLI. This is a standard method for adding plugins that are not yet published to npm. Ensure you have Cordova installed and configured. ```shell $cordova plugin add https://github.com/simplifier-ag/cordova-plugin-ble-peripheral.git ``` -------------------------------- ### Install @nodelib/fs.stat using npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/@nodelib/fs.stat/README.md Installs the @nodelib/fs.stat package, a utility for getting file status, using the npm package manager. This is a prerequisite for using the package in your Node.js project. ```console npm install @nodelib/fs.stat ``` -------------------------------- ### Install p-finally Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/p-finally/readme.md Install the p-finally package using npm. This command downloads and adds the package to your project's dependencies. ```shell npm install --save p-finally ``` -------------------------------- ### Install dependencies and run tests Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/is-extglob/README.md This command installs the development dependencies for the project and then runs the test suite. It's typically used by developers to ensure the code is functioning correctly. ```sh npm install -d && npm test ``` -------------------------------- ### Browserify Command Line Bundling Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/browserify/readme.markdown This snippet shows the basic command-line usage of Browserify to create a bundle. It takes an entry point file (`main.js`) and outputs the bundled JavaScript to another file (`bundle.js`). This is the core command for generating a Browserify-compatible script. ```bash browserify main.js > bundle.js ``` -------------------------------- ### Install Punycode.js via Component Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/url/node_modules/punycode/README.md This command installs the Punycode.js library using Component, a front-end package manager. It's an alternative for managing front-end dependencies. ```bash component install bestiejs/punycode.js ``` -------------------------------- ### Initialize Browserify Instance Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/browserify/readme.markdown Creates a new Browserify instance with optional entry files and configuration options. Supports various input types for files and a comprehensive options object for customization. ```javascript const browserify = require('browserify'); // With entry files const b = browserify(['./src/main.js', './lib/util.js'], { basedir: './src' }); // With options only const b2 = browserify({ entries: ['./src/main.js'], transform: ['babelify'], debug: true }); // No arguments const b3 = browserify(); ``` -------------------------------- ### Install is-buffer using npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/is-buffer/README.md This command installs the 'is-buffer' package, which is a dependency for the usage examples. It is typically run in a terminal or command prompt. ```bash npm install is-buffer ``` -------------------------------- ### Browserify Installation via npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/browserify/readme.markdown This code snippet illustrates how to install the Browserify command-line tool globally using npm. This allows you to use the `browserify` command in your terminal to bundle your JavaScript modules. ```bash npm install -g browserify ``` -------------------------------- ### Get Main Application Installation ID Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/readme.md Fetches the unique installation ID of the main application. This ID can be used for various tracking or identification purposes within the application ecosystem. ```javascript console.log(cordova.plugins.condo.hostApplication.installationID()); ``` -------------------------------- ### Install queue-microtask via npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/queue-microtask/README.md This command installs the `queue-microtask` package using npm. It's a prerequisite for using the library in your Node.js or browser project. ```bash npm install queue-microtask ``` -------------------------------- ### Install JSONStream via npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/JSONStream/readme.markdown Installs the JSONStream module using npm. This is the first step to using the library in your Node.js project. ```bash npm install JSONStream ``` -------------------------------- ### Build and Package Lodash Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/lodash/release.md Builds the lodash library, generates documentation, and prepares distribution files including core, minified, and modularized versions. It also copies necessary files for packaging. ```sh npm run build npm run doc mkdir ../lodash-temp cp lodash.js dist/lodash.min.js dist/lodash.core.js dist/lodash.core.min.js ../lodash-temp/ cp ../lodash-temp/lodash.core.js core.js cp ../lodash-temp/lodash.core.min.js core.min.js cp ../lodash-temp/lodash.js lodash.js cp ../lodash-temp/lodash.min.js lodash.min.js ``` -------------------------------- ### Install shasum-object using npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/shasum-object/README.md This snippet shows the command to install the shasum-object package using npm. This is a prerequisite for using the package in a Node.js project. ```bash npm install shasum-object ``` -------------------------------- ### Browserify API: Basic Bundling Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/browserify/readme.markdown Shows how to use the Browserify API programmatically in Node.js. It initializes a Browserify instance, adds an entry point file ('./browser/main.js'), and pipes the bundled output to standard output. This approach allows for dynamic configuration and integration within larger build processes. ```javascript var browserify = require('browserify'); var b = browserify(); b.add('./browser/main.js'); b.bundle().pipe(process.stdout); ``` -------------------------------- ### Install Cordova Camera Plugin (Shell) Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/plugins/cordova-plugin-camera/doc/fr/index.md This command installs the cordova-plugin-camera using the Cordova CLI. It's a prerequisite for using any of the plugin's functionalities. ```shell Cordova plugin add cordova-plugin-camera ``` -------------------------------- ### Windows Cordova Build Scripts Command Line Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/readme.md A sequence of commands for Windows users to prepare and package the Cordova project for Android. It involves navigating to the Cordova application directory, preparing the iOS platform (which is used to build the `www.zip`), creating the `www.zip` archive, and copying it to the Android project's raw resources directory. ```bash cd MainCordovaApplication cordova prepare ios tar -a -c -f www.zip www copy /y www.zip ..\app\src\main\res\raw\www.zip ``` -------------------------------- ### Install console-browserify with npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/console-browserify/README.md This command installs the console-browserify package using npm. It's the standard way to add the package as a dependency to your project if you're not using a bundler that includes it automatically. ```bash npm install console-browserify ``` -------------------------------- ### Install path-key using npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/path-key/readme.md This snippet shows how to install the path-key package using npm, a common package manager for Node.js projects. This is a prerequisite for using the package in your application. ```bash npm install path-key ``` -------------------------------- ### Install Buffer Module with npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/buffer/README.md Installs the 'buffer' module using npm. This is the standard method for adding the module to your project when not using a bundler directly. ```bash npm install buffer ``` -------------------------------- ### Example: SourceWrapper Implementation Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/concat-stream/node_modules/readable-stream/doc/stream.markdown An example demonstrating how to wrap a low-level source object with a pause/resume mechanism into a `Readable` stream. ```APIDOC ### Example: Wrapping a Low-Level Source ```javascript // Assuming 'util' is required and 'Readable' is accessible const util = require('util'); const { Readable } = require('stream'); function SourceWrapper(options) { Readable.call(this, options); this._source = getLowlevelSourceObject(); // Replace with actual source retrieval this._source.ondata = (chunk) => { // If push() returns false, stop reading from source if (!this.push(chunk)) this._source.readStop(); }; this._source.onend = () => { // Signal end of stream this.push(null); }; } util.inherits(SourceWrapper, Readable); // _read will be called when the stream wants to pull more data SourceWrapper.prototype._read = function(size) { this._source.readStart(); }; // Usage: // const wrapper = new SourceWrapper(); // wrapper.pipe(process.stdout); ``` ``` -------------------------------- ### Install fast-glob using npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/fast-glob/README.md This command installs the fast-glob package, which is a Node.js module that provides fast and efficient file searching using glob patterns. ```console npm install fast-glob ``` -------------------------------- ### Browserify Module Initialization Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/browserify/readme.markdown Illustrates the basic setup for using the Browserify module in a Node.js environment. It shows how to require the browserify package, which is the entry point for programmatic use of the bundler. ```javascript var browserify = require('browserify') ``` -------------------------------- ### Get Parent Directories in Node.js (dirname) Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/parents/readme.markdown Demonstrates how to use the 'parents' module to get all parent directories of the current directory (__dirname). This is useful for understanding directory structures in Unix-like environments. It requires the 'parents' module to be installed. ```javascript var parents = require('parents'); var dirs = parents(__dirname); console.dir(dirs); ``` -------------------------------- ### Get Parent Directories in Node.js (win32) Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/parents/readme.markdown Shows how to use the 'parents' module to get parent directories for a specified Windows path. This example explicitly sets the platform to 'win32' to handle Windows-specific path conventions. Requires the 'parents' module. ```javascript var parents = require('parents'); var dir = 'C:\\Program Files\\Maxis\\Sim City 2000\\cities'; var dirs = parents(dir, { platform : 'win32' }); console.dir(dirs); ``` -------------------------------- ### Install hash.js using npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/hash.js/README.md This snippet shows how to install the hash.js library using npm, the Node Package Manager. It is a prerequisite for using the library in Node.js projects. ```sh npm install hash.js ``` -------------------------------- ### Install and Setup Cordova Import NPM Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/cordova-import-npm/README.md This snippet shows the commands to install the cordova-import-npm package and set up the necessary hooks and configuration file in a Cordova project. It adds a 'before_prepare' hook to config.xml and creates an empty npmFilesToImport.json. ```bash npm install cordova-import-npm npx setup-cordova-import-npm ``` -------------------------------- ### Install parents Module via npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/parents/readme.markdown Provides the command to install the 'parents' Node.js module using npm. This is a prerequisite for using the module in your projects. ```bash npm install parents ``` -------------------------------- ### Get Source Map Module Reference Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/source-map/README.md Provides examples for obtaining a reference to the 'source-map' module in different JavaScript environments, including Node.js and browser builds. ```javascript // Node.js var sourceMap = require('source-map'); // Browser builds var sourceMap = window.sourceMap; // Inside Firefox const sourceMap = require("devtools/toolkit/sourcemap/source-map.js"); ``` -------------------------------- ### Get Host Application Environment Info (JavaScript) Source: https://context7.com/open-condo-software/mobile_cordova_android_demoapplication/llms.txt Synchronously retrieves information about the host application environment using Cordova plugins. It checks for demo environment status, gets the server base URL, installation ID, device ID, and application locale. This information is crucial for configuring API clients, analytics, and internationalization. ```javascript document.addEventListener('deviceready', function() { // Check if running in demo environment const isDemoEnv = cordova.plugins.condo.hostApplication.isDemoEnvironment(); console.log("Is Demo Environment:", isDemoEnv); if (isDemoEnv) { document.body.classList.add('demo-mode'); enableDebugTools(); } // Get base server URL const baseURL = cordova.plugins.condo.hostApplication.baseURL(); console.log("Server Base URL:", baseURL); // Configure API client const apiClient = new ApiClient({ baseURL: baseURL, headers: {'X-App-Type': 'miniapp'} }); // Get installation ID for analytics const installationID = cordova.plugins.condo.hostApplication.installationID(); console.log("Installation ID:", installationID); analytics.setUserId(installationID); // Get device ID for device-specific operations const deviceID = cordova.plugins.condo.hostApplication.deviceID(); console.log("Device ID:", deviceID); localStorage.setItem('deviceId', deviceID); // Get application locale for i18n const locale = cordova.plugins.condo.hostApplication.locale(); console.log("App Locale:", locale); // Set up internationalization i18n.changeLanguage(locale); document.documentElement.lang = locale; }, false); ``` -------------------------------- ### Install Benchmark Dependencies - Shell Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/micromatch/README.md Installs the necessary dependencies to run performance benchmarks for the glob pattern libraries. This command should be executed within the 'bench' directory. ```shell cd bench && npm install ``` -------------------------------- ### JavaScript: Take Photo and Get File URI Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/plugins/cordova-plugin-camera/doc/fr/index.md Example of taking a photo using the Cordova camera plugin and retrieving the image's file URI. The `destinationType` is set to `Camera.DestinationType.FILE_URI`. ```javascript navigator.camera.getPicture (onSuccess, onFail, { quality: 50, destinationType: Camera.DestinationType.FILE_URI }) ; function onSuccess(imageURI) { var image = document.getElementById('myImage') ; image.SRC = imageURI ; } function onFail(message) { alert (' a échoué car: "+ message); } ``` -------------------------------- ### Install balanced-match using npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/balanced-match/README.md Provides the command to install the balanced-match package using npm, the Node Package Manager. This is the standard method for adding the library as a dependency to a Node.js project. ```bash npm install balanced-match ``` -------------------------------- ### Install Punycode.js via npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/url/node_modules/punycode/README.md This command installs the Punycode.js library using npm, a package manager for Node.js. It's primarily for older Node.js versions prior to v0.6.2. ```bash npm install punycode ``` -------------------------------- ### HTML Structure for vm-browserify Example (HTML) Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/vm-browserify/readme.markdown This HTML snippet sets up the basic structure for the vm-browserify example. It includes necessary scripts for jQuery and the bundled JavaScript file (bundle.js), and a span element to display the result of the executed code. ```html result = ``` -------------------------------- ### Ignoring Patterns with Micromatch Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/micromatch/README.md This example shows how to use the `ignore` option in micromatch to specify glob patterns for files that should be ignored during matching. It demonstrates matching all files except those starting with 'f'. ```javascript const isMatch = micromatch.matcher('*', { ignore: 'f*' }); console.log(isMatch('foo')) //=> false console.log(isMatch('bar')) //=> true console.log(isMatch('baz')) //=> true ``` -------------------------------- ### JavaScript: Take Photo and Get Base64 Encoded Image Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/plugins/cordova-plugin-camera/doc/fr/index.md Example of taking a photo using the Cordova camera plugin and receiving the image data as a base64-encoded string. The `destinationType` is set to `Camera.DestinationType.DATA_URL`. ```javascript navigator.camera.getPicture (onSuccess, onFail, { quality: 50, destinationType: Camera.DestinationType.DATA_URL }) ; function onSuccess(imageData) { var image = document.getElementById('myImage') ; image.src = "données : image / jpeg ; base64," + imageData; } function onFail(message) { alert (' a échoué car: "+ message); } ``` -------------------------------- ### Build Acorn from Source Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/acorn/README.md These commands demonstrate how to clone the Acorn repository from GitHub, navigate into the project directory, and install its dependencies using npm. This is an alternative installation method for developers who wish to build Acorn themselves. ```sh git clone https://github.com/acornjs/acorn.git cd acorn npm install ``` -------------------------------- ### Install browser-pack via npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/browser-pack/readme.markdown Commands to install the `browser-pack` package for local project use or global command-line access. ```bash npm install browser-pack ``` ```bash npm install -g browser-pack ``` -------------------------------- ### Browserify Transform Example with insert-module-globals Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/insert-module-globals/readme.markdown Demonstrates how to use insert-module-globals as a transform in a module-deps and browser-pack pipeline. It shows the setup for processing JavaScript files and piping the output through the transform. ```javascript var mdeps = require('module-deps'); var bpack = require('browser-pack'); var insert = require('insert-module-globals'); function inserter (file) { return insert(file, { basedir: __dirname + '/files' }); } var files = [ __dirname + '/files/main.js' ]; mdeps(files, { transform: inserter }) .pipe(bpack({ raw: true })) .pipe(process.stdout) ; ``` -------------------------------- ### Install Brace Expansion Library via npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/brace-expansion/README.md Provides the command to install the `brace-expansion` library using npm, the Node Package Manager. This is a prerequisite for using the library in a Node.js project. ```bash npm install brace-expansion ``` -------------------------------- ### Install typedarray with npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/typedarray/readme.markdown Provides the command to install the typedarray module using npm, the Node Package Manager. This is the standard way to add the library to a Node.js project. ```bash npm install typedarray ``` -------------------------------- ### Example Cordova Platform Definition Object Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/cordova-js/README.md A practical example of a platform definition object for an 'atari' platform. It demonstrates the usage of `id`, `initialize`, and nested `objects` with `path` and `children` for defining global objects. ```json { "id": "atari", "initialize": function() { console.log('firing up Cordova in my Atari, yo.'); }, "objects": { "cordova": { "path": "cordova", "children": { "joystick": { "path": "cordova/plugin/atari/joystick" } } } } } ``` -------------------------------- ### Usage of get-assigned-identifiers in JavaScript Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/get-assigned-identifiers/README.md This example demonstrates how to use the 'get-assigned-identifiers' function in JavaScript. It requires parsing JavaScript code into an AST, selecting a specific node, and then passing it to the function to get the initialized identifiers, correctly handling destructuring. ```javascript var getAssignedIdentifiers = require('get-assigned-identifiers') var ast = parse( 'var { a, b: [ c,, ...x ], d } = whatever()' ) var node = ast.body[0].declarations[0].id getAssignedIdentifiers(node) // → [{ name: 'a' }, { name: 'c' }, { name: 'x' }, { name: 'd' }] ``` -------------------------------- ### Usage Examples for shasum-object Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/shasum-object/README.md Demonstrates how to use the shasum-object function with different input types: a string, a file buffer, and a JSON object. The function can compute the hash using different algorithms and encodings as specified in the API. ```javascript var fs = require('fs') var shasum = require('shasum-object') shasum('of a string') shasum(fs.readFileSync('of-a-file.txt')) shasum({ of: ['an', 'object'] }) ``` -------------------------------- ### Install Acorn using npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/acorn/README.md This command installs the Acorn JavaScript parser from the npm registry. Acorn is a dependency for projects that need to parse JavaScript code. ```sh npm install acorn ``` -------------------------------- ### Custom FileSystemAdapter Implementation - TypeScript Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/@nodelib/fs.stat/README.md Provides an example of how to replace the default Node.js `fs` module with a custom `FileSystemAdapter` in the `Settings` for @nodelib/fs.stat. This allows for mocking or using alternative file system implementations. ```typescript interface FileSystemAdapter { lstat?: typeof fs.lstat; stat?: typeof fs.stat; lstatSync?: typeof fs.lstatSync; statSync?: typeof fs.statSync; } const settings = new fsStat.Settings({ fs: { lstat: fakeLstat } }); ``` -------------------------------- ### JavaScript: Acorn.js AST Node Example Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/detective/node_modules/acorn/README.md Illustrates the structure of a node within an Abstract Syntax Tree (AST) generated by Acorn.js when the 'locations' option is enabled. This shows the 'type', 'start', 'end', and 'loc' properties of a node. ```javascript { "type": "FunctionDeclaration", "start": 0, "end": 31, "loc": { "start": {"line": 1, "column": 0}, "end": {"line": 1, "column": 31} }, "id": { "type": "Identifier", "start": 9, "end": 14, "loc": {"start": {"line": 1, "column": 9}, "end": {"line": 1, "column": 14}}, "name": "hello" }, "params": [], "body": { "type": "BlockStatement", "start": 17, "end": 31, "loc": {"start": {"line": 1, "column": 17}, "end": {"line": 1, "column": 31}}, "body": [ { "type": "ReturnStatement", "start": 19, "end": 30, "loc": {"start": {"line": 1, "column": 19}, "end": {"line": 1, "column": 30}}, "argument": { "type": "Literal", "start": 26, "end": 30, "loc": {"start": {"line": 1, "column": 26}, "end": {"line": 1, "column": 30}}, "value": "world", "raw": "'world'" } } ], "directives": [] }, "generator": false, "async": false } ``` -------------------------------- ### Simple AST Traversal with Acorn Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/acorn-walk/README.md Demonstrates a 'simple' walk over an Abstract Syntax Tree (AST) generated by acorn. It uses the `walk.simple` function to visit nodes, specifically targeting 'Literal' nodes and logging their values. Requires `acorn` and `acorn-walk` to be installed. ```javascript const acorn = require("acorn") const walk = require("acorn-walk") walk.simple(acorn.parse("let x = 10"), { Literal(node) { console.log(`Found a literal: ${node.value}`) } }) ``` -------------------------------- ### Asynchronous File Stat with Options - TypeScript Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/@nodelib/fs.stat/README.md Shows examples of calling the asynchronous `stat` function with different option configurations. This includes providing an empty options object or a pre-instantiated `Settings` object for customized file status retrieval. ```typescript fsStat.stat('path', (error, stats) => { /* … */ }); fsStat.stat('path', {}, (error, stats) => { /* … */ }); fsStat.stat('path', new fsStat.Settings(), (error, stats) => { /* … */ }); ``` -------------------------------- ### Shell: Install global tools and build documentation Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/fill-range/README.md This command installs specific global npm packages required for documentation generation and then runs the documentation build process. It's used for projects that rely on tools like 'verb' for managing their README files. ```sh $ npm install -g verbose/verb#dev verb-generate-readme && verb ``` -------------------------------- ### Get Range of Balanced String Pairs with balanced-match.range Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/balanced-match/README.md Illustrates the usage of the `balanced.range` function from the balanced-match library. This function returns an array containing the start and end indices of the first non-nested matching pair of specified strings within a target string. If no match is found, it returns undefined. ```javascript var balanced = require('balanced-match'); // Example usage for balanced.range (assuming it's used similarly to balanced) // Note: The provided text doesn't show a direct code example for .range, only its description. // This is a placeholder demonstrating the API description. console.log(balanced.range('{', '}', 'pre{in{nested}}post')); // Expected output: [ 3, 14 ] ``` -------------------------------- ### Install Acorn AST Walker via npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/acorn-walk/README.md This command installs the acorn-walk package using npm, a Node Package Manager. This is the recommended way to add the library to your project. No specific inputs or outputs are defined, but successful execution will make the package available for use. ```sh npm install acorn-walk ``` -------------------------------- ### module-deps CLI Usage Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/module-deps/readme.markdown Example command-line usage for the module-deps tool, illustrating how to specify entry point files and apply transformations using the -t (transform) and -g (global transform) flags. ```bash module-deps [FILES] OPTIONS OPTIONS are: -t TRANSFORM Apply a TRANSFORM. -g TRANSFORM Apply a global TRANSFORM. ``` -------------------------------- ### Match Balanced String Pairs with balanced-match Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/balanced-match/README.md Demonstrates how to use the balanced-match library to find the first non-nested matching pair of specified strings (or regular expressions) within a larger string. It shows examples of matching simple braces and regular expression patterns, and the output format includes the start and end indices, preamble, body, and postscript of the match. ```javascript var balanced = require('balanced-match'); console.log(balanced('{', '}', 'pre{in{nested}}post')); console.log(balanced('{', '}', 'pre{first}between{second}post')); console.log(balanced(/\s+\{\s+/, /\s+\}\s+/, 'pre { in{nest} } post')); ``` -------------------------------- ### Build Documentation with Verb Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/braces/README.md Installs the verbose and verb-generate-readme tools globally and then runs the verb command to generate the project's README.md file from its template. ```bash npm install -g verbose/verb#dev verb-generate-readme && verb ``` -------------------------------- ### Synchronous Object Reuse Example with reusify (JavaScript) Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/reusify/README.md Demonstrates how to use reusify to create a reusable object pool for synchronous operations. It shows how to get an object from the pool, set its state, reset it, and release it back to the pool. Proper state resetting (e.g., setting external objects to null instead of deleting) is highlighted for performance. ```javascript var reusify = require('reusify') var fib = require('reusify/benchmarks/fib') var instance = reusify(MyObject) // get an object from the cache, // or creates a new one when cache is empty var obj = instance.get() // set the state obj.num = 100 obj.func() // reset the state. // if the state contains any external object // do not use delete operator (it is slow) // prefer set them to null obj.num = 0 // store an object in the cache instance.release(obj) function MyObject () { // you need to define this property // so V8 can compile MyObject into an // hidden class this.next = null this.num = 0 var that = this // this function is never reallocated, // so it can be optimized by V8 this.func = function () { if (null) { // do nothing } else { // calculates fibonacci fib(that.num) } } } ``` -------------------------------- ### Initialize acorn-node Syntax Tree Walker Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/acorn-node/README.md Requires the walk module from acorn-node, which provides a preconfigured syntax tree walker. This walker is set up with the necessary plugins for acorn-node's enhanced syntax support. ```javascript var walk = require('acorn-node/walk') ``` -------------------------------- ### Parse XML Document using node-elementtree (JavaScript) Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/elementtree/README.md This example illustrates parsing an XML document and querying it using XPath selectors with the node-elementtree library in JavaScript. It reads an XML file, parses its content, and then uses methods like findall, findtext, and get to extract specific data. This showcases the library's ability to navigate and extract information from XML structures. ```javascript var fs = require('fs'); var et = require('elementtree'); var XML = et.XML; var ElementTree = et.ElementTree; var element = et.Element; var subElement = et.SubElement; var data, etree; data = fs.readFileSync('document.xml').toString(); etree = et.parse(data); console.log(etree.findall('./entry/TenantId').length); // 2 console.log(etree.findtext('./entry/ServiceName')); // MaaS console.log(etree.findall('./entry/category')[0].get('term')); // monitoring.entity.create console.log(etree.findall('*/category/[@term="monitoring.entity.update"]').length); // 1 ``` -------------------------------- ### Browserify Plugin Usage with Options Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/browserify/readme.markdown Demonstrates the command-line syntax for using Browserify plugins with options. Plugins extend Browserify's functionality beyond transforms. Options are passed using 'subarg' syntax, enclosed in square brackets after the plugin name. ```bash browserify x.js y.js -p [ factor-bundle -o bundle/x.js -o bundle/y.js ] > bundle/common.js ``` -------------------------------- ### Install read-chunk using npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/read-chunk/readme.md This command installs the 'read-chunk' package and its dependencies using npm, the Node Package Manager. Ensure you have Node.js and npm installed. ```bash npm install read-chunk ``` -------------------------------- ### Install path-parse via npm Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/path-parse/README.md This command installs the 'path-parse' package as a dependency for your project using npm. It's a straightforward installation process for Node.js projects. ```bash npm install --save path-parse ``` -------------------------------- ### Creating BLE Service Programmatically (JavaScript) Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/plugins/cordova-plugin-ble-peripheral/README.md This example shows how to define and publish a BLE service and its characteristics programmatically without using a JSON structure. It involves separate calls to create the service, add characteristics with specified properties and permissions, publish the service, and then start advertising. Note that descriptors are not supported in this programmatic approach for version 1.0. ```javascript Promise.all([ blePeripheral.createService(SERVICE_UUID), blePeripheral.addCharacteristic(SERVICE_UUID, TX_UUID, property.WRITE, permission.WRITEABLE), blePeripheral.addCharacteristic(SERVICE_UUID, RX_UUID, property.READ | property.NOTIFY, permission.READABLE), blePeripheral.publishService(SERVICE_UUID), blePeripheral.startAdvertising(SERVICE_UUID, 'UART') ]).then( function() { console.log ('Created UART Service'); }, app.onError ); ``` -------------------------------- ### Install Duplexer2 via npm (Shell) Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/duplexer2/README.md This command installs the duplexer2 module using npm, the Node Package Manager. Ensure you have Node.js and npm installed globally on your system. ```bash npm i duplexer2 ``` -------------------------------- ### Shell: Install dependencies and run tests Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/fill-range/README.md This command installs the necessary project dependencies using npm and then executes the test suite. It's a standard command for setting up and verifying the functionality of a Node.js project. ```sh $ npm install && npm test ``` -------------------------------- ### Cordova Camera Options Configuration Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/plugins/cordova-plugin-camera/doc/es/README.md This snippet shows an example of how to configure optional parameters for the camera in a Cordova application. It demonstrates setting quality, destination type, source type, and other image-related settings. ```javascript { quality: 75, destinationType: Camera.DestinationType.DATA_URL, sourceType: Camera.PictureSourceType.CAMERA, allowEdit: true, encodingType: Camera.EncodingType.JPEG, targetWidth: 100, targetHeight: 100, popoverOptions: CameraPopoverOptions, saveToPhotoAlbum: false } ``` -------------------------------- ### PhoneGap Plugin Installation Command (Shell) Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/plugins/cordova-plugin-ble-peripheral/README.md This command installs the BLE Peripheral plugin using the PhoneGap CLI. Similar to Cordova, this command adds the plugin from its GitHub repository. Ensure PhoneGap is installed and set up in your environment. ```shell $phonegap plugin add https://github.com/simplifier-ag/cordova-plugin-ble-peripheral.git ``` -------------------------------- ### Add Entry Files to Browserify Instance Source: https://github.com/open-condo-software/mobile_cordova_android_demoapplication/blob/master/MainCordovaApplication/node_modules/browserify/readme.markdown Adds one or more entry files to an existing Browserify instance. Each file added will be executed when the bundle loads. ```javascript const browserify = require('browserify'); const b = browserify(); // Add a single file b.add('./src/main.js'); // Add multiple files b.add(['./src/entry1.js', './src/entry2.js']); // Add with options b.add('./src/another.js', { expose: 'my-module' }); ```