是否有eslint规则来检查typescript错误TS2345?例如,当接口没有所有所需的值时。
Argument of type '{ toValue: number; fieldName: number; }' is not assignable to parameter of type 'SomeConfig'.
Property 'otherProp' is missing in type '{ toValue: number; fieldName: number; }' but required in type 'SomeConfig'.ts(2345)发布于 2020-05-10 05:58:04
所以在使用Typescript运行react-native-web时,我尝试使用Animated API时遇到了这个错误。如果这是您的情况,那么我可以很有把握地告诉您,解决此问题的方法是将本地驱动程序设置为false。useNativeDriver: false
发布于 2020-05-23 06:01:04
没有检查此错误的eslint规则,并且需要构建TypeScript项目才能触发此错误。增加build:"tsc -p“您的package.json的“脚本”部分将允许您运行yarn build来显示此错误。
https://stackoverflow.com/questions/61670206
复制相似问题