如果产生其他依赖无法编译的问题,可以尝试将
pubspec.yaml
中的dependencies
中的所有依赖的"^"去掉,重新编译尝试。
获取新肺炎实时动态App,支持Android和IOS。
-
2020.09.03 - 适配Flutter 1.20
-
2020.07.04 - 适配Flutter 1.17
-
2020.02.16 - 修复统计图不能展示问题。(16:45)
-
2020.02.16 - 辟谣卡片标题最大行数调整为2行,统计数据布局优化。(16:32)
-
2020.02.16 - 完美适配Flutter1.12.13和Androidx(13:21)
-
2020.02.06 - 修复了统计信息出错和诊疗无图标和对齐问题。
-
2020.02.02 - 修复了统计的分隔符导致统计数据无法正常显示。
http://www.flutterj.com/nCoV-2019.apk
IOS:
拉下代码直接跑即可
- cached_network_image
在pubspec.yaml
文件中,关于flutter版本使用cached_network_image
插件问题,默认使用2.0.0,
因为你们刚安装上flutter为最新版本flutter。
# cached_network_image: 1.1.1 # 1.9.0左右flutter版本的用这个
cached_network_image: 2.0.0 # 2.0.0左右flutter版本直接用这个
- 使用命令(拉取项目):$ git clone https://github.com/fluttercandies/ncov_2019.git
- 然后命令(获取依赖):$ flutter packages get (IOS执行IOS部分再执行下一步)
- 最后命令(运行):$ flutter run
IOS
- 进入项目IOS目录:$ cd ios/
- 更新Pod(非必须):$ pod update
- 安装Pod:$ pod install
q1deMacBook-Pro:ncov_2019 q1$ flutter doctor -v
[✓] Flutter (Channel stable, 1.20.2, on Mac OS X 10.14.5 18F2059, locale zh-Hans-CN)
• Flutter version 1.20.2 at /Users/q1/flutter
• Framework revision bbfbf1770c (3 weeks ago), 2020-08-13 08:33:09 -0700
• Engine revision 9d5b21729f
• Dart version 2.9.1
• Pub download mirror https://pub.flutter-io.cn
• Flutter download mirror https://storage.flutter-io.cn
[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.3)
• Android SDK at /Users/q1/Library/Android/sdk
• Platform android-29, build-tools 29.0.3
• ANDROID_HOME = /Users/q1/Library/Android/sdk
• Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
• Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6222593)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 11.3)
• Xcode at /Applications/Xcode.app/Contents/Developer
• Xcode 11.3, Build version 11C29
• CocoaPods version 1.8.4
[✓] Android Studio (version 4.0)
• Android Studio at /Applications/Android Studio.app/Contents
• Flutter plugin version 48.1.2
• Dart plugin version 193.7361
• Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6222593)
[✓] VS Code (version 1.47.3)
• VS Code at /Applications/Visual Studio Code.app/Contents
• Flutter extension version 3.12.2
[✓] Connected device (1 available)
• sdk gphone x86 arm (mobile) • emulator-5554 • android-x86 • Android 11 (API 30) (emulator)
• No issues found!
如果大家有好的意见或者有好的设计图的话可以群内找我。
Flutter交流QQ群:874592746
Flutter交流微信群:
fluttercandies/ncov_2019 is licensed under the
Apache License 2.0
A permissive license whose main conditions require preservation of copyright and license notices.
Contributors provide an express grant of patent rights.
Licensed works, modifications, and larger works may be distributed under different terms and without source code.