DocumentGroupLaunchScene corrupts the toolbar for DocumentGroup content views.

The sample code provided in "Building a document-based app with SwiftUI" (https://developer.apple.com/documentation/swiftui/building-a-document-based-app-with-swiftui) does not work as expected.

The DocumentGroup/StoryView toolbar does not appear for documents opened in the App.

By removing the DocumentGroupLaunchScene block from the App the toolbar does appear and works as expected - but of course the App's DocumentGroupLaunchScene customizations are lost.

I've tested this on 18.0 devices, as well as production 18.0 and 18.1 beta 6 simulators.

If I modify the StoryView by wrapping the content in a NavigationStack I can make some progress - but the results are unstable and hard to pin down - with this change the first time a document is opened in the WritingApp the toolbar appears as expected. When opening a document subsequently the toolbar is corrupted.

Please is this a bug or is there a good example of incorporate both DocumentGroupLaunchScene customizations at the App level and retina the toolbar in documents presented via DocumentGroup?

@chrisfromboulder I'd greatly appreciate it if you could open a bug report, and post the FB number here once you do. Bug Reporting: How and Why? has tips on creating your bug report.

I've now reported this in bug report FB15567398.

DocumentGroup is so broken. Every new Xcode seem to produce just more and more issues with it.

Due DocumentGroup the toolbar or my app is totally broken! Uninstall-rate is about 80%! Please fix DocumentGroup!

No response on filing FB15567398 - and two months on and the bug remains. It would be great to get some feedback and an indication that something will be done to make DocumentGroup do what it says on the tin. This is blocking me from going fully SwiftUI for an App - so I am stuck with Frankenstein mode for a while longer.

DocumentGroupLaunchScene corrupts the toolbar for DocumentGroup content views.
 
 
Q