使用https://pub.dartlang.org/packages/flutter_downloader。不要忘记进行平台配置。
基本上,这就是您应该使用软件包的方式。链接中有一个详细的详细示例。
final taskId = await FlutterDownloader.enqueue( url: 'your download link', savedDir: 'the path of directory where you want to save downloaded files', showNotification: true, // show download progress in status bar (for Android) openFileFromNotification: true, // click on notification to open downloaded file (for Android));



