【发布时间】:2021-07-30 08:03:48
【问题描述】:
我的 Flutter pubspec.yaml 没有得到包。这个错误显示:
Error on line 30, column 22 of pubspec.yaml: Invalid version constraint: Expected version number after "^" in "^^4.2.1", got "^4.2.1".
╷
30 │ animated_text_kit: ^^4.2.1
│ ^^^^^^^
╵
pub get failed (65; ╵)
exit code 65
这是我的依赖:
dependencies:
flutter:
sdk: flutter
# The following adds the Cupertino Icons font to your application.
# Use with the CupertinoIcons class for iOS style icons.
animated_text_kit: ^4.2.1
cupertino_icons: ^1.0.3
audioplayers: ^0.16.1
dev_dependencies:
flutter_test:
sdk: flutter
我检查了缩进、版本等。
我该怎么办?
【问题讨论】:
-
你能添加你的 pubspec.yaml 文件吗
-
检查缩进(制表符与空格)、其他字符等。