我相信这是YAML语法错误,但我找不到它在哪里。
最近我在项目中添加了一个新的字体(Manrope),现在我的Flutter packages get出错了。在添加字体之前,它可以正常工作。
以下是pubspec.yaml的相关部分:
最近我在项目中添加了一个新的字体(Manrope),现在我的Flutter packages get出错了。在添加字体之前,它可以正常工作。
以下是pubspec.yaml的相关部分:
flutter:
uses-material-design: true
assets:
- assets/
fonts:
- family: Hanken Grotesk
fonts:
- asset: fonts/HankenGrotesk-Regular.otf
- asset: fonts/HankenGrotesk-Bold.otf
weight: 700
- asset: fonts/HankenGrotesk-SemiBold.otf
weight: 600
- asset: fonts/HankenGrotesk-Medium.otf
weight: 500
- asset: fonts/HankenGrotesk-Light.otf
weight: 300
- asset: fonts/HankenGrotesk-ExtraLight.otf
weight: 200
- family: Manrope
fonts:
- asset: fonts/manrope-regular.otf
- asset: fonts/manrope-bold.otf
weight: 700
- asset: fonts/manrope-semibold.otf
weight: 600
- asset: fonts/manrope-medium.otf
weight: 500
以下是我收到的错误信息:
Error on line 65, column 12 of pubspec.yaml: Mapping values are not allowed here. Did you miss a colon earlier?
fonts:
^
pub get failed (65)