mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-08-12 21:10:23 +00:00
Merge pull request #14414 from larrybahr/master
[cordova-plugin-device-name] new definitions, v1.0
This commit is contained in:
@@ -1,23 +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-plugin-app-version-tests.ts"
|
||||
]
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es6",
|
||||
"dom"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictNullChecks": true,
|
||||
"baseUrl": "../",
|
||||
"typeRoots": [
|
||||
"../"
|
||||
],
|
||||
"types": [],
|
||||
"noEmit": true,
|
||||
"forceConsistentCasingInFileNames": true
|
||||
},
|
||||
"files": [
|
||||
"index.d.ts",
|
||||
"cordova-plugin-app-version-tests.ts"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,8 @@
|
||||
# Installation
|
||||
> `npm install --save @types/cordova-plugin-device-name`
|
||||
|
||||
# Summary
|
||||
This package contains type definitions for cordova-plugin-device-name (https://www.npmjs.com/package/cordova-plugin-device-name)
|
||||
|
||||
# Details
|
||||
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/cordova-plugin-device-name
|
||||
@@ -0,0 +1,4 @@
|
||||
/// <reference types="cordova" />
|
||||
|
||||
var deviceName = cordova.plugins.deviceName;
|
||||
console.log(deviceName.name) // e.g: Becvert's iPad
|
||||
+26
@@ -0,0 +1,26 @@
|
||||
// Type definitions for cordova-plugin-device-name v1.1.0
|
||||
// Project: https://www.npmjs.com/package/cordova-plugin-device-name
|
||||
// Definitions by: Larry Bahr <https://github.com/larrybahr>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
//
|
||||
// Licensed under the MIT license.
|
||||
|
||||
interface CordovaPlugins {
|
||||
/**
|
||||
* cordova-plugin-device-name interface
|
||||
*/
|
||||
deviceName: CordovaPluginDeviceName.CordovaPluginDeviceName;
|
||||
}
|
||||
|
||||
/**
|
||||
* Keep the type global namespace clean by using a module
|
||||
*/
|
||||
declare module CordovaPluginDeviceName {
|
||||
interface CordovaPluginDeviceName {
|
||||
/**
|
||||
* User-friendly name of the device.
|
||||
* @example cordova.plugins.deviceName.name // e.g: Larry's Android
|
||||
*/
|
||||
name: 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-plugin-device-name-tests.ts"
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user