小编Vas*_*oni的帖子

Flutter 中的 Ionicons 包在构建期间显示此警告 - 期望找到 (packages/Ionicons/Ionicons, MaterialIcons) 的字体

我在我的 flutter 应用程序中使用 Ionicons pagckage 作为图标。但是当执行 flutter build appbundle 时,它​​向我显示这个错误 -

Expected to find fonts for (packages/Ionicons/Ionicons, MaterialIcons), but found (MaterialIcons). This usually means you are referring to font families in an IconData class but not including them in the assets section of your pubspec.yaml, are missing the package that would include them, or are missing "uses-material-design: true".
Run Code Online (Sandbox Code Playgroud)

我已经写uses-material-design: true在我的 pubspec.yaml 中了。这是我的 pubspec.yaml 文件 -

name: my_app_name
description: A new Flutter project.

publish_to: 'none'

version: 0.0.9+9

environment:
  sdk: …
Run Code Online (Sandbox Code Playgroud)

dart material-design ionicons flutter

5
推荐指数
1
解决办法
2306
查看次数

标签 统计

dart ×1

flutter ×1

ionicons ×1

material-design ×1