Page 1 of 1

[Implemented] CompilerIf check Android/iOS/Web

Posted: Sat Sep 17, 2022 2:49 pm
by hoerbie
Hi,

don't know if I have overlooked it in the docs, but I didn't find any "CompilerIf" check to switch between commands for Android, iOS and Web.

I've programmed an app for Android and iOS, and I need to include different Cordova extensions for Android and iOS to use bluetooth printer.
I've tried to use a simple "If" checking against "DeviceInfo(#PB_Device_Platform)", that shows "Android" or "iOS" but this doesn't work, when using the

Code: Select all

Import "cordova plugin add ..."
For me it looks, like Import is always executed when compiling with Cordova?

Thanks, hoerbie