JSFileSystemDirectoryHandle extension

Provides a handle to a file system directory. The interface is accessed via the window.showDirectoryPicker method.

Example and more on MDN Web Docs

on

Properties

values Stream<FileSystemHandle>

Available on FileSystemDirectoryHandle, provided by the JSFileSystemDirectoryHandle extension

Asynchronous iterator of FileSystemHandle as found in this directory when called.
no setter

Methods

getDirectoryHandle(String name, {bool create = false}) Future<FileSystemDirectoryHandle>

Available on FileSystemDirectoryHandle, provided by the JSFileSystemDirectoryHandle extension

Returns a Future fulfilled with a FileSystemDirectoryHandle for a subdirectory with the specified name, within this directory.
getFileHandle(String name, {bool create = false}) Future<FileSystemFileHandle>

Available on FileSystemDirectoryHandle, provided by the JSFileSystemDirectoryHandle extension

Returns a Future fulfilled with a FileSystemFileHandle for a file with the specified name, within this directory.
removeEntry(String name, {bool recursive = false}) Future<void>

Available on FileSystemDirectoryHandle, provided by the JSFileSystemDirectoryHandle extension

Attempts to asynchronously remove an entry if the directory handle contains a file or directory called the name specified.
resolve(FileSystemHandle possibleDescendant) Future<List<String>?>

Available on FileSystemDirectoryHandle, provided by the JSFileSystemDirectoryHandle extension

Returns a List of directory names from the parent handle to the specified child entry, with the name of the child entry as the last array item or null if possibleDescendant is not a descendant of this FileSystemDirectoryHandle.