InspectorCommands
A built-in set of commands for manipulating inspectors.
Declaration
struct InspectorCommandsOverview
InspectorCommands include a command for toggling the presented state of the inspector with a keyboard shortcut of Control-Command-I.
These commands are optional and can be explicitly requested by passing a value of this type to the commands(content:) modifier:
@State var presented = true
WindowGroup {
MainView()
.inspector(isPresented: $presented) {
InspectorView()
}
}
.commands {
InspectorCommands()
}