这个url说:
但我在“放大”文件夹或任何其他地方找不到任何"cli.json“文件。
阅读此链接并不能澄清多少问题,但我尝试手动创建一个:
{
"features": {
"enableDartNullSafety":true
}
}我得到了一个错误:
"Invalid feature flag configuration
These feature flags are defined in the "amplify/cli.json" configuration file and are unknown to the currently running Amplify CLI:
- enabledartnullsafety
This issue likely happens when the project has been pushed with a newer version of Amplify CLI, try updating to a newer version.
Learn more about feature flags: https://docs.amplify.aws/cli/reference/feature-flags"有什么建议吗?
发布于 2021-07-23 19:33:57
我不知道这是否是正确的做法,可能不是,但它似乎是正常工作。
在我的颤振项目中,我在“放大”文件夹中创建了一个文件"cli.json“,内容如下:
{
"features":{
"codegen": {
"enableDartNullSafety":true
}
}
}在放大cli上执行“放大码元模型”显示:
Detected feature flag: “enableDartNullSafety : true”
Generating Dart Models with null safety所以,它看起来很管用。
https://stackoverflow.com/questions/68503291
复制相似问题