I want my app to open a folder and read (optionally edit) the files inside it. From the SwiftUI documentation it looks like DocumentGroup might be a good solution since I wouldn't need to manually handle the bookmarks / permissions.
How do I use DocumentGroup for this?
The following code crashes upon startup:
DocumentGroup(
editing: CodeRepository.self,
contentType: .directory
) {
Text("editor view")
}
To be clear this is to open an view any user selected folder. Not a folder with a custom file extension.