How do I check which platform the code is executing on , i.e., web browers, vs Android APK, vs iPhone?
I want to be able to use this in my Typescript or in an element property, i.e., [[hidden]
How do I check which platform the code is executing on , i.e., web browers, vs Android APK, vs iPhone?
I want to be able to use this in my Typescript or in an element property, i.e., [[hidden]
Hello,
Please search online for an appropriate solution. There are a lot of examples:
https://stackoverflow.com/questions/518 ... ng-ionic-4
https://forum.ionicframework.com/t/how- ... /138189/10
I ended up using the ionic Platform (https://ionicframework.com/docs/angular/platform) service .
As its already in Appery all I had to in the screen I want to check the platfrom is:
add Platform to the "Internal includes", i.e., code/includes
add the variable "platform", type Platform and checked DI
call this.platform.platforms().includes('cordova')