Skip to content

Latest commit

 

History

History
37 lines (31 loc) · 1.16 KB

README-CN.md

File metadata and controls

37 lines (31 loc) · 1.16 KB

一、使用说明

dependencies:
  flutter_app_update: ^latest_version
  • 创建UpdateModel设置下载地址
 UpdateModel model = UpdateModel(
   url,
   "flutterUpdate.apk",
   /// android res/mipmap 目录下的图片名称
   "ic_launcher",
   'https://itunes.apple.com/cn/app/抖音/id1142110895',
 );
 AzhonAppUpdate.update(model).then((value) => debugPrint('$value'));
  • 监听下载过程
@override
void initState() {
  super.initState();
  AzhonAppUpdate.listener((ResultModel model) {
    debugPrint('$model');
  });
}

三、效果图