0 purchases
flutter media scanner
flutter_media_scanner #
Use this plugin to refresh the filesystem after writing a file
Example #
Scaffold(
appBar: AppBar(
title: const Text('FlutterMediaScanner example'),
),
body: Center(
child: OutlineButton(
onPressed: () async {
File originalFile = File("original path");
List<int> bytes = await originalFile.readAsBytes();
//save your file to your desired path
File file = File("path");
await file.writeAsBytes(bytes);
//refresh the file system so the file can show there,
await FlutterMediaScanner.scan(file.path);
},
child: const Text("Save & refresh!"),
),
),
)
copied to clipboard
For personal and professional use. You cannot resell or redistribute these repositories in their original state.
There are no reviews.