writeFileAsBytes method
Write bytes
inside fileName
and return the path to the file.
Files are saved in the following locations:
- Android: Device's external downloads directory.
- iOS: Application's Documents directory.
- MacOS: Applications's Documents directory.
- Web: Browser's downloads directory.
MacOS only: This method will also open the finder pointing to the folder containing the file.
Implementation
Future<String> writeFileAsBytes({
required String fileName,
required Uint8List bytes,
}) =>
_platform.writeFile(
fileName: fileName,
bytes: bytes,
);