mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-10-06 07:47:04 +00:00
Added cordova_app_version_plugin
Added type definitions for https://www.npmjs.com/package/cordova_app_version_plugin
This commit is contained in:
@@ -0,0 +1,8 @@
|
||||
# Installation
|
||||
> `npm install --save @types/cordova_app_version_plugin`
|
||||
|
||||
# Summary
|
||||
This package contains type definitions for cordova_app_version_plugin (https://www.npmjs.com/package/cordova_app_version_plugin)
|
||||
|
||||
# Details
|
||||
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/cordova_app_version_plugin
|
||||
@@ -0,0 +1,3 @@
|
||||
/// <reference types="cordova" />
|
||||
|
||||
var appVersion = window.cordova.plugins.version.getAppVersion(); // e.g. "1.5.0"
|
||||
+26
@@ -0,0 +1,26 @@
|
||||
// Type definitions for cordova_app_version_plugin v0.2.6
|
||||
// Project: https://www.npmjs.com/package/cordova_app_version_plugin
|
||||
// Definitions by: Larry Bahr <https://github.com/larrybahr>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
//
|
||||
// Licensed under the MIT license.
|
||||
|
||||
interface CordovaPlugins {
|
||||
/**
|
||||
* cordova_app_version_plugin interface
|
||||
*/
|
||||
version: CordovaAppVersionPlugin.CordovaAppVersionPlugin;
|
||||
}
|
||||
|
||||
/**
|
||||
* Keep the type global namespace clean by using a module
|
||||
*/
|
||||
declare module CordovaAppVersionPlugin {
|
||||
interface CordovaAppVersionPlugin {
|
||||
/**
|
||||
* App version from config.xml's version (e.g. <widget id="my.app.id" version="1.5.0">)
|
||||
* @example window.cordova.plugins.version.getAppVersion() // e.g: "1.5.0"
|
||||
*/
|
||||
getAppVersion(): string;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es6",
|
||||
"dom"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictNullChecks": false,
|
||||
"baseUrl": "../",
|
||||
"typeRoots": [
|
||||
"../"
|
||||
],
|
||||
"types": [],
|
||||
"noEmit": true,
|
||||
"forceConsistentCasingInFileNames": true
|
||||
},
|
||||
"files": [
|
||||
"index.d.ts",
|
||||
"cordova_app_version_plugin-tests.ts"
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user