Flutter项目删除了相关的dart文件之后运行flutter run或者 F5编译运行时会报这个错误.... were declared as an inputs, but did not exist. Check the definition of target:kernel_snapshot for errors
我所做的项目报的错误是这样的
因为报错内容主要是".... were declared as an inputs, but did not exist. Check the definition of target:kernel_snapshot for errors",应该时删除了文件之后,运行时找不到对应的文件,感觉时缓存问题,没有自动更新到那个文件(kernel_snapshot.d)的内容,导致这个文件里面还会存在之前删除了的文件的路径,这个时候只要运行一下flutter clean清楚一下快照缓存,之后再次执行flutter run就成功了
刚接触Flutter,继续学习吧