0
I am now starting to use Ionic, and would like to know how to get the device Imei number using Ionic 2.
I tried to that, but I didn’t understand how to install the plugin
0
I am now starting to use Ionic, and would like to know how to get the device Imei number using Ionic 2.
I tried to that, but I didn’t understand how to install the plugin
0
Ionic provides access to some device information on which it runs, for example: device model, operating system version, serial number and uuid.
In the terminal, inside the project folder, it is necessary to execute the following commands:
ionic cordova plugin add cordova-plugin-device
npm install --save @ionic-native/device
In your file . ts, use as follows:
import { Device } from '@ionic-native/device';
constructor(private device: Device) {}
getImei(){
console.log(this.device.uuid);
}
Browser other questions tagged apache-cordova ionic2 hybrid-app
You are not signed in. Login or sign up in order to post.