I have an app I wrote many years ago in Objective-C that I had converted it to Swift, and now I converted it to SwiftUI. When converting to SwiftUI I had all my model files as structs. I decided to convert to the new Swift Navigation API released in iOS16, since the old way is deprecated and I would be gaining some features that I have wanted for years. However, this causes multiple infinite loops that I have been trying to track down for months. I finally requested Apple Developer Technical support, which ended up being no help. I then narrowed this issue down to using a binding and I think it is a bug so I submitted a bug report FB12069067 to Apple.
The only solution I see, without Apple acknowledging this is a bug and fixing it, it to convert all my model files from structs to class as ObservableObjects, and instead of passing a binding I can use the observed object. I’d have to change a significant amount of code, but I see no other solution. I have found an article by Apple that seems to imply that I should use a class for my model files.
https://developer.apple.com/documentation/swiftui/managing-model-data-in-your-app
I’m curious what everyone else is doing. When using SwiftUI, is your model with struct/Binding or class/ObservableObject?