使用缓存图片 - Flutter中文网
wendux opened this issue · 16 comments
一口气读完了 跟着Google老大 没失望过 0.0
读完了,发现一个小失误 :emailRegexp 变量名跟下面引用的不匹配
你们美国人怎么这么牛?
布局讲解的很赞 有么有关于网络传输的内容啊
怎么控制一个view,显示或者隐藏
牛逼
这文档真详细,66666
终于看完了,了解了个大概,需要写项目才能进度额
对于怎么动态隐藏和显示,我实践了一下,可以在setState里面动态添加布局,不添加时即可隐藏,添加时即可显示。 setState(() {
if (toggle) {
return new Text('Toggle One');
}
});
显示和隐藏使用 Offstage 里面有一个属性 offstage默认为true(隐藏),设置为false就会显示,
CachedNetworkImage
图片加载成功,怎么还一直loading?
CachedNetworkImage这种方式怎么加载不到图片呀
前排露脸
嗯,在canvas绘制的时候,CustomPaint绘制区域没有Size,不能进行绘制,需要加上一个属性size : new Size(double.infinity, double.infinity)才能绘制出来
@wendux 配置完依赖点击pub get后出现这个错误怎么解决?
D:\software\flutter\bin\flutter.bat --no-color pub get
fatal: ambiguous argument 'HEAD': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions, like this:
'git [...] -- [...]'
Running "flutter pub get" in my_first_flutter_app...
The current Flutter SDK version is 0.0.0-unknown.
Because myfirstflutterapp depends on cached_network_image >=2.0.0-rc which requires Flutter SDK version >=1.10.15-pre.148 <2.0.0, version solving failed.
pub get failed (1; Because myfirstflutterapp depends on cached_network_image >=2.0.0-rc which requires Flutter SDK version >=1.10.15-pre.148 <2.0.0, version solving failed.)
Process finished with exit code 1
我yaml文件的配置是
environment:
sdk: ">=2.7.0 <3.0.0"
dependencies:
cached_network_image: ^2.2.0+1
flutter:
sdk: flutter
@wendux 配置完依赖点击pub get后出现这个错误怎么解决?
D:\software\flutter\bin\flutter.bat --no-color pub get
fatal: ambiguous argument 'HEAD': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions, like this:
'git [...] -- [...]'
Running "flutter pub get" in my_first_flutter_app...
The current Flutter SDK version is 0.0.0-unknown.Because myfirstflutterapp depends on cached_network_image >=2.0.0-rc which requires Flutter SDK version >=1.10.15-pre.148 <2.0.0, version solving failed.
pub get failed (1; Because myfirstflutterapp depends on cached_network_image >=2.0.0-rc which requires Flutter SDK version >=1.10.15-pre.148 <2.0.0, version solving failed.)
Process finished with exit code 1我yaml文件的配置是
environment:
sdk: ">=2.7.0 <3.0.0"dependencies:
cached_network_image: ^2.2.0+1
flutter:
sdk: flutter
解决了。安装flutter以下载压缩包方式会有问题,采用clone方式安装什么问题都没有了。建议flutter中文网也可以改为推荐clone方式。