mirror of
https://github.com/danielsogl/awesome-cordova-plugins.git
synced 2025-04-01 20:32:55 +08:00
53 lines
1.2 KiB
TypeScript
53 lines
1.2 KiB
TypeScript
export interface CordovaPlugin {
|
|
id: string,
|
|
className: string;
|
|
plugin: string;
|
|
pluginRef: string;
|
|
promise?: any //should really be Promise
|
|
}
|
|
|
|
|
|
export var PluginConfig:CordovaPlugin[] = [
|
|
{
|
|
id: 'device',
|
|
className: 'Device',
|
|
plugin: 'cordova-plugin-device',
|
|
pluginRef: 'device'
|
|
},
|
|
{
|
|
id: 'camera',
|
|
className: 'Camera',
|
|
plugin: 'cordova-plugin-camera',
|
|
promise: ['takePicture'],
|
|
pluginRef: 'navigator.camera'
|
|
},
|
|
{
|
|
id: 'statusbar',
|
|
className: 'StatusBar',
|
|
plugin: 'cordova-plugin-statusbar',
|
|
pluginRef: 'StatusBar',
|
|
promise: ['show', 'hide', 'styleDefault', 'styleLightContent', 'styleBlackTranslucent', 'styleBlackOpaque']
|
|
},
|
|
{
|
|
id: 'applinks',
|
|
className: 'AppLinks',
|
|
plugin: 'com.lampa.startapp',
|
|
pluginRef: 'navigator.startApp',
|
|
promise: ['start', 'check']
|
|
},
|
|
{
|
|
id: 'barcode',
|
|
className: 'Barcode',
|
|
plugin: 'phonegap-plugin-barcodescanner',
|
|
pluginRef: 'cordova.plugins.barcodeScanner',
|
|
promise: ['scan', 'encode']
|
|
},
|
|
{
|
|
id: 'camera-roll',
|
|
className: 'CameraRoll',
|
|
plugin: 'cordova-plugin-camera-roll',
|
|
pluginRef: 'CameraRoll',
|
|
promise: ['saveToCameraRoll', 'getPhotos']
|
|
},
|
|
]
|