fileDialogDefaultDirectory

Configures the fileExporter, fileImporter, or fileMover to open with the specified default directory.

View ModifieriOS 17.0+macOS 14.0+fileDialogDefaultDirectory(_:) in SwiftUI

Declaration

React
compose().fileDialogDefaultDirectory(
  defaultDirectory: string | null
)
Swift
nonisolated func fileDialogDefaultDirectory(
    _ defaultDirectory: URL?
) -> some View

Parameters

  • defaultDirectory*string | null

    The directory to show when the system file dialog launches. If the given file dialog has a fileDialogCustomizationID if stores the user-chosen directory and subsequently opens with it, ignoring the default value provided in this modifier.

See also

More in Presentation.