You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Because the Skip tooling does not know the value of any symbols other than os(Android) and !os(Android), we strongly recommend adding os(Android) or !os(Android) conditions to all #if blocks, so that it is clear whether Skip should include or exclude the code for Android.
That line made no sense at all to me when I read it.
What it means to say is that #if !os(macOS) won't work, which is filed as #342. You have to rewrite it as #if !os(macOS) || os(Android).
The documentation would be much clearer with an example of issue #342 and the recommended workaround.
For example, this won't work, because Skip doesn't understand the symbol os(macOS), or its negation !os(macOS).
Text("Hello World")#if !os(macOS)
// BUG this won't run on Android
.italic()#endif
https://skip.tools/docs/platformcustomization/#compiler-directives includes this warning:
That line made no sense at all to me when I read it.
What it means to say is that
#if !os(macOS)
won't work, which is filed as #342. You have to rewrite it as#if !os(macOS) || os(Android)
.The documentation would be much clearer with an example of issue #342 and the recommended workaround.
The text was updated successfully, but these errors were encountered: