file_manager
1.0.2, released 4 years ago by an unverified publisher
A Flutter widget and controller to manage, browse, and pick files and folders.
What it does
Provides a FileManager widget and FileManagerController to display file system entities in a list, navigate directories, sort files by various parameters, and handle folder creation and file access permissions.
AI-written summary of version 1.0.2, based on the package's README and metadata. Report an inaccuracy
Use it when
- You want to build an in-app file explorer or directory navigator in Flutter.
- You need to list files and folders and allow users to open directories or pick files.
Skip it when
- You are targeting platforms without full support like MacOS or Windows, where support is currently missing or in progress.
- You only need to pick a single file or media item using native system pickers.
Strengths
- Easy integration with standard Flutter list views via a builder and snapshot pattern.
- Includes built-in sorting capabilities (by name, type, date, and size).
- Provides a ControlBackButton widget to easily manage system back button behavior in subdirectories.
Weaknesses
- Windows and MacOS support are not fully implemented or have active issues.
- Requires manual native permission configuration for Android storage access.
Setup
- Kind
- Flutter widgets
- Effort
- Medium
- Code generation
- No
- Direct dependencies
- 1
Requires adding storage permissions (WRITE_EXTERNAL_STORAGE, READ_EXTERNAL_STORAGE, MANAGE_EXTERNAL_STORAGE) and requestLegacyExternalStorage to AndroidManifest.xml, alongside runtime permission requests.
FileManager(
controller: controller,
builder: (context, snapshot) {
final List<FileSystemEntity> entities = snapshot;
return ListView.builder(
itemCount: entities.length,
itemBuilder: (context, index) {
return ListTile(
title: Text(FileManager.basename(entities[index])),
);
},
);
},
)Alternatives
Packages that do the same job and could replace file_manager.
- cross_file
An abstraction to allow working with files across multiple platforms.
90Compare - file_picker
Use the native file explorer to pick single or multiple files, directories, and save files.
93Compare - file_selector_macos
macOS implementation of the file_selector plugin
82Compare - flutter_downloader
Plugin to create and manage background download tasks on Android and iOS.
80Compare
Works with
Packages commonly used together with file_manager: ones it builds on, ones built on it, and its own family.