我们有严格的零排放政策。这意味着所有错误和警告都需要修复。
在我们的项目中,面对这一愚蠢的错误:
warning Unexpected any. Specify a different type @typescript-eslint/no-explicit-any
在Google和lint网站上搜索。我没有找到这样的解决办法!
尝试过:// eslint:@typescript-eslint/no-explicit-any: "off"
不起作用
有没有人知道如何在React项目中绕过这个eslint
规则?
发布于 2021-10-26 11:08:31
在角度上,我们把它加到TypeScript规则中。在一般规则中没有,因为有时这不起作用。
示例:
"rules": {
"@typescript-eslint/no-explicit-any": ["off"]
}
在.eslintrc.json文件中
https://stackoverflow.com/questions/58467000
复制相似问题