[英]Flutter Material Icons changed after upgrading SDK to 2.2.1 (latest stable)
Usually this happens when your pubspec.yaml file, under dev-dependencies has uses-material-design
set to false and its not including the material icons in your app.通常,当您的 pubspec.yaml 文件在 dev-dependencies 下将uses-material-design
设置为 false 并且它不包括应用程序中的材质图标时,就会发生这种情况。
Change it to true, and restart the app.将其更改为 true,然后重新启动应用程序。 It should work after that.它应该在那之后工作。
I found the issue, the material icon codes where replaced in this SDK and I was using IconData instead of referencing by their name.我发现了这个问题,在这个 SDK 中替换了材质图标代码,我使用的是 IconData 而不是通过它们的名称引用。 So I updated the code to be like:所以我将代码更新为:
Icon(Icons.arrow_back_ios_new_rounded, size: 20)
See https://github.com/flutter/flutter/issues/84427见https://github.com/flutter/flutter/issues/84427
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.