Same issue here. Alas the workaround doesn't work in my case.
I am using a @State variable to store the isActive state and I had noticed it being false after I had set it to true during some renders of the body property. It renders the body with it true then all of a sudden it is false. Its almost like SwiftUI created a totally new View.
I tried putting the isActive state in my view model (I have an MVVM app) but I was able to watch it getting set to false through no action on my own (I guess when SwiftUI popped the newly pushed on view.) I also noticed my viewModel (passed via @EnviromentObject) was also nil during some of the body property calls.
Topic:
UI Frameworks
SubTopic:
SwiftUI
Tags: