Post

Replies

Boosts

Views

Activity

TabView back crash with ScrollView
hello,in the below code, if i navigate to "detailview", switch to the "scroll" tab and press "back", the app crashes with Thread 1: EXC_BAD_ACCESS (code=2, address=...).if i put the ScrollView tab first, pressing back works on either tab. if i remove the ScrollView, it does not crash.can the crash be avoided while retaining the tab order (and having scrollable content)?could it be a swiftui bug?import SwiftUI struct DetailView: View { var body: some View { TabView { Text("tab") .tabItem { Text("tab") } ScrollView { Text("scroll") }.tabItem { Text("scroll") } } } } struct ContentView: View { var body: some View { NavigationView { NavigationLink(destination: DetailView()) { Text("Detail view") } } } } struct ContentView_Previews: PreviewProvider { static var previews: some View { ContentView() } }it is built for iOS 13.2 in xcode 11.3.1. the complete app that i am building crashes on device as well.thanks,lars
2
0
1.7k
Feb ’20