【问题标题】:Can't download package of Bloc Pattern in flutter无法在flutter中下载Bloc Pattern的包
【发布时间】:2021-08-26 03:00:24
【问题描述】:

我想在我的颤振项目中的 pubspec.yaml 文件中导入 bloc_pattern: ^2.3.5 库。我把它写在 yaml 文件中,成功运行了 pub get 命令,但是由于某种原因,它的包没有在 dart 包中显示,这导致 import 'package:bloc_pattern/bloc_pattern.dart'; 下的红线我已经使用了这些命令 flutter clean 和 @ 987654324@ 但红线仍然存在。我也尝试更改库的版本,但不能使用最新的空安全库,因为目前我使用的是flutter version 1.22.4。请帮忙!

【问题讨论】:

  • 关闭并打开您的编辑器
  • 如果您对特定版本没有要求,请不要特定版本,完全只使用这种 bloc_pattern: ,它会自动安装适当的插件版本。
  • 问题仍然存在。真的很奇怪很沮丧

标签: flutter dart state-management


【解决方案1】:

重启你的ide。 运行flutter clean 运行flutter pub get

【讨论】:

  • 我已经这样做了几次,但问题仍然存在。
  • 好的,请告诉我飞镖分析问题选项卡中的确切错误列表。
猜你喜欢
  • 2020-04-15
  • 2021-09-20
  • 2021-03-11
  • 2021-02-08
  • 2021-10-26
  • 2020-08-21
  • 2020-03-28
  • 2020-04-28
  • 2021-05-23
相关资源
最近更新 更多