Using the below example, if you scroll all the way down the onAppear seems to not trigger. Or it does sometimes occasionally but very inconsistent. As soon as I remove the listStyle modifier everything works as expected. Am I doing anything wrong here, or is this a swiftUI bug?
struct ContentView: View {
@State var listOfItems = Array(0...100)
var body: some View {
List {
ForEach(listOfItems, id: \.self) { item in
Text("\(item)")
}
Text("Hello, world!")
.onAppear {
print("I appeared")
}
}
.listStyle(PlainListStyle())
}
}