For some reason it seems that my NavigationLink is only working on long press. Here's a snippet of the View:
struct MainView: View {
@EnvironmentObject var user: UserObservable
var body: some View {
VStack {
NavigationView {
List(user.items, id: \.self) { item in
NavigationLink(destination: ItemView(item: item)) {
Text(item.name)
}
}
.navigationBarTitle("\(user.displayName)'s items")
.navigationBarItems(leading: AddItemViewButton().environmentObject(user),
trailing: MainViewActionSheet().environmentObject(user))
}
}
}
}
The list is populated correctly but tapping on them does nothing. Pressing and holding and then releasing does open the correct destination.
Has anyone else seen anything like this? This is on Xcode 11.4.1 and iOS 13.4.1.