This bug is still in the Release Candidate. It means when you have a document based #SwiftUI app, you can't use leading items in the navigation bar. They will just disappear every time the app saves the changes in a document. 😔
https://mastodon.social/@sandropennisi/110809303766894687
@sandropennisi I also saw @bdewey having issues with DocumentGroup + NavigationStack. https://iosdev.space/@bdewey/111041862162653396
For what it’s worth, the navigation APIs have been absolutely shocking. Not sure what’s going on over there.
@phill @bdewey oh that’s interesting. Yeah i have tons of weird behavior with navigation too in some of my other apps. Very weird. And document based SwiftUI app was broken from the start. Now in some areas it’s better but broken in new ones. It feels like i have to work around weird issues all the time.
@sandropennisi @bdewey do yourself a favour: stop using these APIs. Seriously.
Write a light wrapper around UINavigationController. It won’t take you long, and I guarantee you’ll have far fewer issues. And if you do, you can actually fix them.
Happy to exchange notes if you’re interested :-)
@sandropennisi AFAIK DocumentGroup is a wrapper around UIDocument + view management, so I’d say it’s still worth exploring your own. 99.99% of my SwiftUI issues are at the UIKit/AppKit border. Apple’s implementations for whatever reason are just extremely problematic.
@phill i guess you’re right. I’ll probably make an example project to test if i can do it. Thanks again for the input