mapping - 解析块映射时需要一个键
问题描述
在 pubspec.yaml 中检测到错误:
Error on line 48, column 4: Expected a key while parsing a block mapping.
pubspec.yaml:
flutter:
uses-material-design: true
assets:
- images/googlelogo.png
解决方案
正如您在评论中提到的那样,缩进在 pubspec.yaml 文件中很重要。它应该是这样的:
flutter:
uses-material-design: true
assets:
- images/googlelogo.png
推荐阅读
- python - mypy 泛型可以表达将返回序列类型作为参数传递吗?
- reactjs - Auth0 SPA TypeError:无法读取未定义的属性“idTokenPayload”
- c - Stack-Smashing Protection 错误消息不包含程序名称
- javascript - 如何将{variable}连接到react js中的href标签?
- laravel - 如何使用 auth 命令给出的重置密码 mailable
- python-3.x - 无法使用 PyInstaller/ 创建工作 PyQt5 Python 可执行文件
- sql - 循环遍历不同的表进行计数
- mysql - 如何获得单行中多列的最大值?
- python - 脚本不过滤脏话不和谐 py
- python-3.x - 当脚本本身正在导入许多其他模块时在分析器下运行脚本,其中一个模块由于已知功能而非常慢