Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dart 2.9 打开空安全后全错了,有计划兼容嘛? #30

Open
TshineZheng opened this issue Aug 14, 2020 · 3 comments
Open

dart 2.9 打开空安全后全错了,有计划兼容嘛? #30

TshineZheng opened this issue Aug 14, 2020 · 3 comments

Comments

@TshineZheng
Copy link

刚升了 Flutter 1.20,并尝试迁移代码到 non-nullable,突然发现用这个工具生成的 json 代码全部都报错了。

@debuggerx01
Copy link
Owner

我更新了以后没碰到你说的错误 能详细说下什么情况吗

@TshineZheng
Copy link
Author

@debuggerx01 空安全打开了吗?
升到最新的话 dart 应该是 2.9。
analysis_options.yaml 文件中加入

analyzer:
  enable-experiment:
    - non-nullable

调整pubspec.yaml中的sdk版本为

environment:
  sdk: ">=2.9.0 <3.0.0"

@debuggerx01
Copy link
Owner

@TshineZheng null-safety 分支更新了 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants