mirror of
https://github.com/danielsogl/awesome-cordova-plugins.git
synced 2025-01-19 16:52:53 +08:00
feat(couchbase-lite): add CouchbaseLite cordova plugin (#1025)
* feat(CouchbaseLite): add CouchbaseLite cordova plugin * add plugin url
This commit is contained in:
parent
fd8107b79a
commit
09a7dcf594
@ -32,6 +32,7 @@ import { CardIO } from './plugins/card-io';
|
||||
import { Clipboard } from './plugins/clipboard';
|
||||
import { CodePush } from './plugins/code-push';
|
||||
import { Contacts } from './plugins/contacts';
|
||||
import { CouchbaseLite } from './plugins/couchbase-lite';
|
||||
import { Crop } from './plugins/crop';
|
||||
import { DatePicker } from './plugins/datepicker';
|
||||
import { DBMeter } from './plugins/dbmeter';
|
||||
@ -159,6 +160,7 @@ export * from './plugins/card-io';
|
||||
export * from './plugins/clipboard';
|
||||
export * from './plugins/code-push';
|
||||
export * from './plugins/contacts';
|
||||
export * from './plugins/couchbase-lite';
|
||||
export * from './plugins/crop';
|
||||
export * from './plugins/datepicker';
|
||||
export * from './plugins/dbmeter';
|
||||
@ -288,6 +290,7 @@ window['IonicNative'] = {
|
||||
Clipboard,
|
||||
CodePush,
|
||||
Contacts,
|
||||
CouchbaseLite,
|
||||
Crop,
|
||||
DatePicker,
|
||||
DBMeter,
|
||||
|
35
src/plugins/couchbase-lite.ts
Normal file
35
src/plugins/couchbase-lite.ts
Normal file
@ -0,0 +1,35 @@
|
||||
import { Plugin, Cordova } from './plugin';
|
||||
|
||||
/**
|
||||
* @name Couchbase Lite
|
||||
* @description
|
||||
* Plugin to install Couchbase Lite in your PhoneGap app on iOS or Android
|
||||
*
|
||||
* @usage
|
||||
* ```
|
||||
* import { CouchbaseLite } from 'ionic-native';
|
||||
*
|
||||
* CouchbaseLite.getURL()
|
||||
* .then((url: any) => console.log(url))
|
||||
* .catch((error: any) => console.log(error));
|
||||
*
|
||||
* ```
|
||||
*/
|
||||
@Plugin({
|
||||
pluginName: 'CouchbaseLite',
|
||||
plugin: 'https://github.com/couchbaselabs/Couchbase-Lite-PhoneGap-Plugin',
|
||||
pluginRef: 'cblite',
|
||||
repo: 'https://github.com/couchbaselabs/Couchbase-Lite-PhoneGap-Plugin',
|
||||
})
|
||||
export class CouchbaseLite {
|
||||
|
||||
/**
|
||||
* Get the database url
|
||||
* @return {Promise<any>} Returns a promise that resolves with the local database url
|
||||
*/
|
||||
@Cordova({
|
||||
callbackStyle: 'node'
|
||||
})
|
||||
static getURL(): Promise<any> { return; }
|
||||
|
||||
}
|
Loading…
Reference in New Issue
Block a user