I have discovered a regression in watchOS 8.1RC with NavigationLink triggered from a TabView. It's immediately dismissed.
It was working in watchOS 8.0 or in Simulator (watchOS 8.0). Do you know a workaround ? Thanks
Sample code:
import SwiftUI
@main
struct TestNavigationApp: App {
var body: some Scene {
WindowGroup {
NavigationView {
ContentView()
}
}
}
}
struct ContentView: View {
var body: some View {
List {
NavigationLink(destination: ContentView1()) {
Text("To TabView")
}
}
}
}
struct ContentView1: View {
var body: some View {
TabView {
NavigationView {
NavigationLink(destination: ContentView2()) {
Text("To ContentView2")
}
}
VStack {
Text("Screen2")
}
}
}
}
struct ContentView2: View {
var body: some View {
Text("ContentView2")
}
}
struct ContentView_Previews: PreviewProvider {
static var previews: some View {
ContentView()
}
}
NavigationLink
in your code has no chance of working. – Trahurn