mirror of
https://github.com/danielsogl/awesome-cordova-plugins.git
synced 2026-07-16 00:00:04 +08:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
93ce443467 | ||
|
|
f3c5ebd28b | ||
|
|
bcd46eea9d | ||
|
|
689bfd9568 | ||
|
|
dcf3ab2787 | ||
|
|
b4158f4f85 | ||
|
|
0a54929169 | ||
|
|
e34f94e0c1 | ||
|
|
d4c6ea46e6 | ||
|
|
203d4c7669 | ||
|
|
8cd6686803 | ||
|
|
aaddd9eea2 | ||
|
|
c9b76c4a9a | ||
|
|
0e5bdc2f1e | ||
|
|
4b08d854bd |
@@ -1,3 +1,41 @@
|
||||
<a name="1.3.15"></a>
|
||||
## [1.3.15](https://github.com/driftyco/ionic-native/compare/v1.3.14...v1.3.15) (2016-08-15)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* **google-analytics:** add missing functions ([689bfd9](https://github.com/driftyco/ionic-native/commit/689bfd9))
|
||||
* **TTS:** add tts plugin ([#431](https://github.com/driftyco/ionic-native/issues/431)) ([dcf3ab2](https://github.com/driftyco/ionic-native/commit/dcf3ab2)), closes [#311](https://github.com/driftyco/ionic-native/issues/311)
|
||||
|
||||
|
||||
|
||||
<a name="1.3.14"></a>
|
||||
## [1.3.14](https://github.com/driftyco/ionic-native/compare/v1.3.13...v1.3.14) (2016-08-15)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* **datepicker:** date now accepts Date, string, or number ([#428](https://github.com/driftyco/ionic-native/issues/428)) ([aaddd9e](https://github.com/driftyco/ionic-native/commit/aaddd9e)), closes [#354](https://github.com/driftyco/ionic-native/issues/354)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* **native-audio:** Add native audio plugin ([#427](https://github.com/driftyco/ionic-native/issues/427)) ([8cd6686](https://github.com/driftyco/ionic-native/commit/8cd6686)), closes [#315](https://github.com/driftyco/ionic-native/issues/315)
|
||||
* **shake:** add Shake plugin ([#426](https://github.com/driftyco/ionic-native/issues/426)) ([203d4c7](https://github.com/driftyco/ionic-native/commit/203d4c7)), closes [#313](https://github.com/driftyco/ionic-native/issues/313)
|
||||
* **zip:** add zip plugin ([#430](https://github.com/driftyco/ionic-native/issues/430)) ([e34f94e](https://github.com/driftyco/ionic-native/commit/e34f94e)), closes [#421](https://github.com/driftyco/ionic-native/issues/421)
|
||||
|
||||
|
||||
|
||||
<a name="1.3.13"></a>
|
||||
## [1.3.13](https://github.com/driftyco/ionic-native/compare/v1.3.12...v1.3.13) (2016-08-13)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* **inappbrowser:** fix event listener ([4b08d85](https://github.com/driftyco/ionic-native/commit/4b08d85))
|
||||
|
||||
|
||||
|
||||
<a name="1.3.12"></a>
|
||||
## [1.3.12](https://github.com/driftyco/ionic-native/compare/v1.3.10...v1.3.12) (2016-08-13)
|
||||
|
||||
|
||||
@@ -5,6 +5,16 @@ This is a short guide on creating new plugin wrappers for Ionic Native.
|
||||
|
||||
## Creating Plugin Wrappers
|
||||
|
||||
First, let's start by creating a new plugin wrapper from template.
|
||||
|
||||
```
|
||||
// Call this command, and replace PluginName with the name of the plugin you wish to add
|
||||
// Make sure to capitalize the first letter, or use CamelCase if necessary.
|
||||
|
||||
gulp plugin:create -n PluginName
|
||||
```
|
||||
|
||||
|
||||
Let's take a look at the existing plugin wrapper for Geolocation to see what goes into an Ionic Native plugin (comments have been removed for clarity):
|
||||
|
||||
```
|
||||
|
||||
@@ -0,0 +1,50 @@
|
||||
/**
|
||||
* This is a template for new plugin wrappers
|
||||
*
|
||||
* TODO:
|
||||
* - Add/Change information below
|
||||
* - Document usage (importing, executing main functionality)
|
||||
* - Remove any imports that you are not using
|
||||
* - Add this file to /src/index.ts (follow style of other plugins)
|
||||
* - Remove all the comments included in this template, EXCEPT the @Plugin wrapper docs.
|
||||
* - Remove this note
|
||||
*
|
||||
*/
|
||||
import {Plugin, Cordova, CordovaProperty, CordovaInstance, InstanceProperty} from './plugin';
|
||||
import {Observable} from 'rxjs/Observable';
|
||||
|
||||
/**
|
||||
* @name PluginName
|
||||
* @description
|
||||
* This plugin does something
|
||||
*
|
||||
* @usage
|
||||
* ```
|
||||
* import {PluginName} from 'ionic-native';
|
||||
*
|
||||
* PluginName.functionName('Hello', 123)
|
||||
* .then((something: any) => doSomething(something))
|
||||
* .catch((error: any) => console.log(error));
|
||||
*
|
||||
* ```
|
||||
*/
|
||||
@Plugin({
|
||||
plugin: '', // npm package name, example: cordova-plugin-camera
|
||||
pluginRef: '', // the variable reference to call the plugin, example: navigator.geolocation
|
||||
repo: '', // the github repository URL for the plugin
|
||||
install: '' // OPTIONAL install command, in case the plugin requires variables
|
||||
})
|
||||
export class PluginName {
|
||||
|
||||
/**
|
||||
* This function does something
|
||||
* @param arg1 {string} Some param to configure something
|
||||
* @param arg2 {number} Another param to configure something
|
||||
* @return {Promise<any>} Returns a promise that resolves when something happens
|
||||
*/
|
||||
@Cordova()
|
||||
static functionName(arg1: string, arg2: number): Promise<any> {
|
||||
return; // We add return; here to avoid any IDE / Compiler errors
|
||||
}
|
||||
|
||||
}
|
||||
+13
@@ -3,6 +3,8 @@ var minimist = require('minimist');
|
||||
var uglify = require('gulp-uglify');
|
||||
var rename = require("gulp-rename");
|
||||
var tslint = require('ionic-gulp-tslint');
|
||||
var decamelize = require('decamelize');
|
||||
var replace = require('gulp-replace');
|
||||
|
||||
var flagConfig = {
|
||||
string: ['port', 'version', 'ngVersion', 'animations'],
|
||||
@@ -26,3 +28,14 @@ gulp.task("minify:dist", function(){
|
||||
});
|
||||
|
||||
gulp.task('lint', tslint);
|
||||
|
||||
gulp.task('plugin:create', function(){
|
||||
if(flags.n && flags.n !== ''){
|
||||
return gulp.src('./TEMPLATE')
|
||||
.pipe(replace('PluginName', flags.n))
|
||||
.pipe(rename(decamelize(flags.n, '-') + '.ts'))
|
||||
.pipe(gulp.dest('./src/plugins/'));
|
||||
} else {
|
||||
console.log("Usage is: gulp plugin:create -n PluginName");
|
||||
}
|
||||
});
|
||||
|
||||
+5
-2
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "ionic-native",
|
||||
"version": "1.3.12",
|
||||
"version": "1.3.15",
|
||||
"description": "Native plugin wrappers for Cordova and Ionic with TypeScript, ES6+, Promise and Observable support",
|
||||
"main": "dist/index.js",
|
||||
"files": [
|
||||
@@ -16,11 +16,13 @@
|
||||
"conventional-github-releaser": "^1.1.3",
|
||||
"cpr": "^1.0.0",
|
||||
"cz-conventional-changelog": "^1.1.6",
|
||||
"decamelize": "^1.2.0",
|
||||
"dgeni": "^0.4.2",
|
||||
"dgeni-packages": "^0.10.18",
|
||||
"glob": "^6.0.4",
|
||||
"gulp": "^3.9.1",
|
||||
"gulp-rename": "^1.2.2",
|
||||
"gulp-replace": "^0.5.4",
|
||||
"gulp-tslint": "^5.0.0",
|
||||
"gulp-uglify": "^1.5.4",
|
||||
"ionic-gulp-tslint": "^1.0.0",
|
||||
@@ -42,7 +44,8 @@
|
||||
"build:js": "./node_modules/.bin/tsc",
|
||||
"build:bundle": "./node_modules/.bin/browserify dist/index.js > dist/ionic.native.js",
|
||||
"build:minify": "./node_modules/.bin/gulp minify:dist",
|
||||
"changelog": "./node_modules/.bin/conventional-changelog -p angular -i CHANGELOG.md -s -r 0"
|
||||
"changelog": "./node_modules/.bin/conventional-changelog -p angular -i CHANGELOG.md -s -r 0",
|
||||
"plugin:create": "gulp plugin:create"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
|
||||
+14
-2
@@ -56,6 +56,7 @@ import {Keyboard} from './plugins/keyboard';
|
||||
import {LaunchNavigator} from './plugins/launchnavigator';
|
||||
import {LocalNotifications} from './plugins/localnotifications';
|
||||
import {MediaCapture} from './plugins/media-capture';
|
||||
import {NativeAudio} from './plugins/native-audio';
|
||||
import {NativeStorage} from './plugins/nativestorage';
|
||||
import {MediaPlugin} from './plugins/media';
|
||||
import {Network} from './plugins/network';
|
||||
@@ -68,6 +69,7 @@ import {Push} from './plugins/push';
|
||||
import {SafariViewController} from './plugins/safari-view-controller';
|
||||
import {Screenshot} from './plugins/screenshot';
|
||||
import {SecureStorage} from './plugins/securestorage';
|
||||
import {Shake} from './plugins/shake';
|
||||
import {Sim} from './plugins/sim';
|
||||
import {SMS} from './plugins/sms';
|
||||
import {SocialSharing} from './plugins/socialsharing';
|
||||
@@ -78,10 +80,12 @@ import {StatusBar} from './plugins/statusbar';
|
||||
import {ThreeDeeTouch} from './plugins/3dtouch';
|
||||
import {Toast} from './plugins/toast';
|
||||
import {TouchID} from './plugins/touchid';
|
||||
import {TextToSpeech} from './plugins/text-to-speech';
|
||||
import {TwitterConnect} from './plugins/twitter-connect';
|
||||
import {Vibration} from './plugins/vibration';
|
||||
import {VideoPlayer} from './plugins/video-player';
|
||||
import {WebIntent} from './plugins/webintent';
|
||||
import {Zip} from './plugins/zip';
|
||||
export * from './plugins/3dtouch';
|
||||
export * from './plugins/background-geolocation';
|
||||
export * from './plugins/backgroundmode';
|
||||
@@ -146,6 +150,7 @@ export {
|
||||
Hotspot,
|
||||
Insomnia,
|
||||
Keyboard,
|
||||
NativeAudio,
|
||||
NativeStorage,
|
||||
Network,
|
||||
OneSignal,
|
||||
@@ -154,6 +159,7 @@ export {
|
||||
PinDialog,
|
||||
Screenshot,
|
||||
SecureStorage,
|
||||
Shake,
|
||||
SocialSharing,
|
||||
Sim,
|
||||
Splashscreen,
|
||||
@@ -161,8 +167,10 @@ export {
|
||||
StatusBar,
|
||||
TouchID,
|
||||
Transfer,
|
||||
TextToSpeech,
|
||||
Vibration,
|
||||
WebIntent
|
||||
WebIntent,
|
||||
Zip
|
||||
}
|
||||
|
||||
export * from './plugins/plugin';
|
||||
@@ -220,6 +228,7 @@ window['IonicNative'] = {
|
||||
LocalNotifications: LocalNotifications,
|
||||
MediaCapture: MediaCapture,
|
||||
MediaPlugin: MediaPlugin,
|
||||
NativeAudio: NativeAudio,
|
||||
NativeStorage: NativeStorage,
|
||||
Network: Network,
|
||||
Printer: Printer,
|
||||
@@ -231,6 +240,7 @@ window['IonicNative'] = {
|
||||
SafariViewController: SafariViewController,
|
||||
Screenshot: Screenshot,
|
||||
SecureStorage: SecureStorage,
|
||||
Shake: Shake,
|
||||
Sim: Sim,
|
||||
SMS: SMS,
|
||||
SocialSharing: SocialSharing,
|
||||
@@ -242,10 +252,12 @@ window['IonicNative'] = {
|
||||
Toast: Toast,
|
||||
TouchID: TouchID,
|
||||
Transfer: Transfer,
|
||||
TextToSpeech: TextToSpeech,
|
||||
TwitterConnect: TwitterConnect,
|
||||
VideoPlayer: VideoPlayer,
|
||||
Vibration: Vibration,
|
||||
WebIntent: WebIntent
|
||||
WebIntent: WebIntent,
|
||||
Zip: Zip
|
||||
};
|
||||
|
||||
initAngular1(window['IonicNative']);
|
||||
|
||||
@@ -13,7 +13,7 @@ export interface DatePickerOptions {
|
||||
* Platforms: iOS, Android, Windows
|
||||
* Selected date
|
||||
*/
|
||||
date: Date;
|
||||
date: Date | string | number;
|
||||
|
||||
/**
|
||||
* Platforms: iOS, Android, Windows
|
||||
@@ -21,7 +21,7 @@ export interface DatePickerOptions {
|
||||
* Type: Date | empty String
|
||||
* Default: empty String
|
||||
*/
|
||||
minDate?: Date;
|
||||
minDate?: Date | string | number;
|
||||
|
||||
/**
|
||||
* Platforms?: iOS, Android, Windows
|
||||
@@ -29,7 +29,7 @@ export interface DatePickerOptions {
|
||||
* Type?: Date | empty String
|
||||
* Default?: empty String
|
||||
*/
|
||||
maxDate?: Date;
|
||||
maxDate?: Date | string | number;
|
||||
|
||||
/**
|
||||
* Platforms?: Android
|
||||
|
||||
@@ -107,13 +107,34 @@ export class GoogleAnalytics {
|
||||
* https://developers.google.com/analytics/devguides/collection/analyticsjs/user-id
|
||||
* @param {string} id
|
||||
*/
|
||||
@Cordova()
|
||||
static setUserId(id: string): Promise<any> { return; }
|
||||
@Cordova({sync: true})
|
||||
static setUserId(id: string): void { }
|
||||
|
||||
/**
|
||||
* Sets the app version
|
||||
* @param appVersion
|
||||
*/
|
||||
@Cordova({sync: true})
|
||||
static setAppVersion(appVersion: string): void { }
|
||||
|
||||
/**
|
||||
* Set a anonymize Ip address
|
||||
* @param anonymize
|
||||
*/
|
||||
@Cordova({sync: true})
|
||||
static setAnonymizeIp(anonymize: boolean): void { }
|
||||
|
||||
/**
|
||||
* Enabling Advertising Features in Google Analytics allows you to take advantage of Remarketing, Demographics & Interests reports, and more
|
||||
* @param allow
|
||||
*/
|
||||
@Cordova({sync: true})
|
||||
static setAllowIDFACollection(allow: boolean): void { }
|
||||
|
||||
/**
|
||||
* Enable verbose logging
|
||||
*/
|
||||
@Cordova()
|
||||
@Cordova({sync: true})
|
||||
static debugMode(): Promise<any> { return; }
|
||||
|
||||
/**
|
||||
|
||||
@@ -96,7 +96,7 @@ export class InAppBrowser {
|
||||
*/
|
||||
on(event: string): Observable<InAppBrowserEvent> {
|
||||
return new Observable<InAppBrowserEvent>((observer) => {
|
||||
this._objectInstance.addEventListener(event, observer.next.bind);
|
||||
this._objectInstance.addEventListener(event, observer.next.bind(observer));
|
||||
return () => this._objectInstance.removeEventListener(event, observer.next.bind(observer));
|
||||
});
|
||||
}
|
||||
|
||||
@@ -0,0 +1,91 @@
|
||||
import {Plugin, Cordova} from './plugin';
|
||||
/**
|
||||
* @name NativeAudio
|
||||
* @description Native Audio Playback
|
||||
* @usage
|
||||
* ```typescript
|
||||
* import {NativeAudio} from 'ionic-native';
|
||||
*
|
||||
* NativeAudio.preloadSimple('uniqueId1', 'path/to/file.mp3').then(onSuccess, onError);
|
||||
* NativeAudio.preloadComplex('uniqueId2', 'path/to/file2.mp3', 1, 1, 0).then(onSuccess, onError);
|
||||
*
|
||||
* NativeAudio.play('uniqueId1').then(onSuccess, onError);
|
||||
* NativeAudio.loop('uniqueId2').then(onSuccess, onError);
|
||||
*
|
||||
* NativeAudio.setVolumeForComplexAsset('uniqueId2', 0.6).then(onSuccess,onError);
|
||||
*
|
||||
* NativeAudio.stop('uniqueId1').then(onSuccess,onError);
|
||||
*
|
||||
* NativeAudio.unload('uniqueId1').then(onSuccess,onError);
|
||||
*
|
||||
* ```
|
||||
*/
|
||||
@Plugin({
|
||||
plugin: 'cordova-plugin-nativeaudio',
|
||||
pluginRef: 'NativeAudio',
|
||||
repo: 'https://github.com/floatinghotpot/cordova-plugin-nativeaudio'
|
||||
})
|
||||
export class NativeAudio {
|
||||
/**
|
||||
* Loads an audio file into memory. Optimized for short clips / single shots (up to five seconds). Cannot be stopped / looped.
|
||||
* @param id {string} unique ID for the audio file
|
||||
* @param assetPath {string} the relative path or absolute URL (inluding http://) to the audio asset.
|
||||
* @returns {Promise<any>}
|
||||
*/
|
||||
@Cordova()
|
||||
static preloadSimple(id: string, assetPath: string): Promise<any> {return; }
|
||||
|
||||
/**
|
||||
* Loads an audio file into memory. Optimized for background music / ambient sound. Uses highlevel native APIs with a larger footprint. (iOS: AVAudioPlayer). Can be stopped / looped and used with multiple voices. Can be faded in and out using the delay parameter.
|
||||
* @param id {string} unique ID for the audio file
|
||||
* @param assetPath {string} the relative path or absolute URL (inluding http://) to the audio asset.
|
||||
* @param volume {number} the volume of the preloaded sound (0.1 to 1.0)
|
||||
* @param voices {number} the number of multichannel voices available
|
||||
* @param delay {number}
|
||||
* @returns {Promise<any>}
|
||||
*/
|
||||
@Cordova()
|
||||
static preloadComplex(id: string, assetPath: string, volume: number, voices: number, delay: number): Promise<any> {return; }
|
||||
|
||||
/**
|
||||
* Plays an audio asset
|
||||
* @param id {string} unique ID for the audio file
|
||||
* @param completeCallback {Function} callback to be invoked when audio is done playing
|
||||
*/
|
||||
@Cordova({
|
||||
successIndex: 1,
|
||||
errorIndex: 2
|
||||
})
|
||||
static play(id: string, completeCallback: Function): Promise<any> {return; }
|
||||
|
||||
/**
|
||||
* Stops playing an audio
|
||||
* @param id {string} unique ID for the audio file
|
||||
*/
|
||||
@Cordova()
|
||||
static stop(id: string): Promise<any> {return; }
|
||||
|
||||
/**
|
||||
* Loops an audio asset infinitely, this only works for complex assets
|
||||
* @param id {string} unique ID for the audio file
|
||||
* @return {Promise<any>}
|
||||
*/
|
||||
@Cordova()
|
||||
static loop(id: string): Promise<any> {return; }
|
||||
|
||||
/**
|
||||
* Unloads an audio file from memory
|
||||
* @param id {string} unique ID for the audio file
|
||||
*/
|
||||
@Cordova()
|
||||
static unload(id: string): Promise<any> {return; }
|
||||
|
||||
/**
|
||||
* Changes the volume for preloaded complex assets.
|
||||
* @param id {string} unique ID for the audio file
|
||||
* @param volume {number} the volume of the audio asset (0.1 to 1.0)
|
||||
*/
|
||||
@Cordova()
|
||||
static setVolumeForComplexAsset(id: string, volume: number): Promise<any> {return; }
|
||||
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
import {Plugin, Cordova} from './plugin';
|
||||
import {Observable} from 'rxjs/Observable';
|
||||
/**
|
||||
* @name Shake
|
||||
* @description Handles shake gesture
|
||||
* @usage
|
||||
* ```typescript
|
||||
* import {Shake} from 'ionic-native';
|
||||
*
|
||||
* let watch = Shake.startWatch(60).subscribe(() => {
|
||||
* // do something
|
||||
* });
|
||||
*
|
||||
* watch.unsubscribe();
|
||||
* ```
|
||||
*/
|
||||
@Plugin({
|
||||
plugin: 'cordova-plugin-shake',
|
||||
pluginRef: 'shake',
|
||||
repo: 'https://github.com/leecrossley/cordova-plugin-shake'
|
||||
})
|
||||
export class Shake {
|
||||
/**
|
||||
* Watch for shake gesture
|
||||
* @param sensitivity {number} Optional sensitivity parameter. Defaults to 40
|
||||
*/
|
||||
@Cordova({
|
||||
observable: true,
|
||||
clearFunction: 'stopWatch',
|
||||
successIndex: 0,
|
||||
errorIndex: 2
|
||||
})
|
||||
static startWatch(sensitivity?: number): Observable<any> {return; }
|
||||
|
||||
}
|
||||
@@ -0,0 +1,47 @@
|
||||
import {Plugin, Cordova} from './plugin';
|
||||
|
||||
export interface TTSOptions {
|
||||
/** text to speak */
|
||||
text: string;
|
||||
/** a string like 'en-US', 'zh-CN', etc */
|
||||
locale?: string;
|
||||
/** speed rate, 0 ~ 1 */
|
||||
rate?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
* @name TTS
|
||||
* @description
|
||||
* Text to Speech plugin
|
||||
*
|
||||
* @usage
|
||||
* ```
|
||||
* import {TTS} from 'ionic-native';
|
||||
*
|
||||
* TTS.speak('Hello World')
|
||||
* .then(() => console.log('Success'))
|
||||
* .catch((reason: any) => console.log(reason));
|
||||
*
|
||||
* ```
|
||||
*/
|
||||
@Plugin({
|
||||
plugin: 'cordova-plugin-tts',
|
||||
pluginRef: 'TTS',
|
||||
repo: 'https://github.com/vilic/cordova-plugin-tts'
|
||||
})
|
||||
export class TextToSpeech {
|
||||
|
||||
/**
|
||||
* This function speaks
|
||||
* @param options {string | TTSOptions} Text to speak or TTSOptions
|
||||
* @return {Promise<any>} Returns a promise that resolves when the speaking finishes
|
||||
*/
|
||||
@Cordova({
|
||||
successIndex: 1,
|
||||
errorIndex: 2
|
||||
})
|
||||
static speak(options: string | TTSOptions): Promise<any> {
|
||||
return;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,39 @@
|
||||
import {Plugin, Cordova} from './plugin';
|
||||
|
||||
/**
|
||||
* @name Zip
|
||||
* @description
|
||||
* A Cordova plugin to unzip files in Android and iOS.
|
||||
*
|
||||
* @usage
|
||||
* ```
|
||||
* import {Zip} from 'ionic-native';
|
||||
*
|
||||
* Zip.unzip('path/to/source.zip', 'path/to/dest', (progress) => console.log('Unzipping, ' + Math.round((progress.loaded / progress.total) * 100) + '%'))
|
||||
* .then((result) => {
|
||||
* if(result === 0) console.log('SUCCESS');
|
||||
* if(result === -1) console.log('FAILED');
|
||||
* });
|
||||
*
|
||||
* ```
|
||||
*/
|
||||
@Plugin({
|
||||
plugin: 'cordova-plugin-zip',
|
||||
pluginRef: 'zip',
|
||||
repo: 'https://github.com/MobileChromeApps/cordova-plugin-zip',
|
||||
})
|
||||
export class Zip {
|
||||
/**
|
||||
* Extracts files from a ZIP archive
|
||||
* @param sourceZip {string} Source ZIP file
|
||||
* @param destUrl {string} Destination folder
|
||||
* @param onProgress {Function} optional callback to be called on progress update
|
||||
* @return {Promise<number>} returns a promise that resolves with a number. 0 is success, -1 is error
|
||||
*/
|
||||
@Cordova({
|
||||
successIndex: 2,
|
||||
errorIndex: 4
|
||||
})
|
||||
static unzip(sourceZip: string, destUrl: string, onProgress: Function): Promise<number> {return; }
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user