这个问题就困扰我很久,一直没法解决。具体表现如下:

偶然google到解决办法:在项目eslintrc.js
中添加一行,症状就消失了,治好了我多年的颈椎病
rules: {
'@typescript-eslint/interface-name-prefix': 'off',
'@typescript-eslint/explicit-function-return-type': 'off',
'@typescript-eslint/explicit-module-boundary-types': 'off',
'@typescript-eslint/no-explicit-any': 'off',
'prettier/prettier': ['error', { endOfLine: 'off' }], //加这一句
},
网友评论