I'd like to display different views when building for iOS and iPadOS. Currently, I know I can do
import SwiftUI
struct ContentView: View {
#if targetEnvironment(macCatalyst)
var body: some View {
Text("Hello")
}
#else
var body: some View {
Text("Hello")
}
#endif
}
to display different views between macOS and iPadOS/iOS (introduced in Swift 4/5). But how do I differentiate between the latter? I can't seem to use targetEnvironment...