downloadsDir property
Implementation
static Future<Directory?> get downloadsDir async {
Directory downloadsDirectory;
try {
if (Platform.isIOS) {
downloadsDirectory = await getLibraryDirectory();
} else {
downloadsDirectory = await getApplicationSupportDirectory();
}
return downloadsDirectory;
} on PlatformException {
return null;
}
}