Property 'device' does not exist on type 'typeof Device'


#1

Hi all ! After upading to 2.0.0-rc.4 I can not build my project to Android. I have error … Help please.

 Property 'device' does not exist on type 'typeof Device'.

    platform.ready().then(() => {
     this.device['uuid'] = Device.device.uuid;
   });

#2

Ionic version: 2

The official docs for the native Device are obsolete.
Example:
The Device object does not have more a device attribute.

Example:
Device.device.uuid wont compile. The compiler outputs

Property ‘device’ does not exist on type ‘typeof Device’.
Now the right implementation is
Device.uuid


#3

freez_1, thx a lot, I solved problem.Do not you know occasionally what happend with this ?


#4

Sorry, no, I don’t know


#5

Device was changed in 2.2.11 of ionic-native: https://github.com/driftyco/ionic-native/releases

Now you just say Device.uuid instead of Device.device.uuid