cordova-plugin-device-name
DefinitelyTyped icon, indicating that this package has TypeScript declarations provided by the separate @types/cordova-plugin-device-name package

1.3.5 • Public • Published

Cordova Device Name Plugin

This plugin allows you to get the user-friendly name of the device.

On Android, a bluetooth adapter is required. Android emulator does not have bluetooth capabilities!

CHANGELOG

Installation

In your application project directory:

cordova plugin add cordova-plugin-device-name

Usage

var deviceName = cordova.plugins.deviceName;
 
console.log(deviceName.name) // e.g: Becvert's iPad
 
deviceName.get(function success(name) {
    console.log(name);
}, function failure(error) {
    console.log(error);
});

if you installed cordova-plugin-device you can use:

window.device.name

Credits

All the credits go to the official cordova-plugin-device plugin.

Licence

The MIT License

Package Sidebar

Install

npm i cordova-plugin-device-name

Weekly Downloads

792

Version

1.3.5

License

MIT

Unpacked Size

11.9 kB

Total Files

11

Last publish

Collaborators

  • becvert