问题描述:
1、使用json_serializable和freezed_annotation时,JsonKey出现提示警告(注释'JsonKey'只能在字段或getter上使用)
analyzer:
errors:
invalid_annotation_target: ignore
解决方法:找到analysis_options.yaml文件,添加如下
image.png
1、使用json_serializable和freezed_annotation时,JsonKey出现提示警告(注释'JsonKey'只能在字段或getter上使用)
analyzer:
errors:
invalid_annotation_target: ignore
解决方法:找到analysis_options.yaml文件,添加如下