Skip to main content

Documentation Index

Fetch the complete documentation index at: https://filekit.mintlify.app/llms.txt

Use this file to discover all available pages before exploring further.

Supported on Android, iOS, macOS, JVM, JS and WASM targets

Quick start

Easily open a folder picker dialog to let users select a directory.
val directory = FileKit.openDirectoryPicker()

Customizing the dialog

You can customize the dialog by setting the initial directory and platform-specific dialogSettings, such as a title on supported platforms.
val directory = FileKit.openDirectoryPicker(
    directory = PlatformFile("/custom/initial/path"),
    dialogSettings = FileKitDialogSettings.createDefault(),
)
Read more about dialog settings to customize the dialog for each platform.
On JS and WASM, directory picking uses the browser webkitdirectory input behavior. Browsers expose the selected directory as a flat list of files, so FileKit rebuilds a virtual directory tree from their relative paths. Empty directories are not available, and directory lastModified() values are synthetic.
macOS System AppearanceOn macOS, to ensure the directory picker dialog uses the system’s theme (light or dark), you may need to set a system property at the start of your application:
System.setProperty("apple.awt.application.appearance", "system")
This is typically done in your main function, before the application window is created.