1 Star 1 Fork 0

王浩枫/TMT-web

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
.eslintrc.js 882 Bytes
一键复制 编辑 原始数据 按行查看 历史
hfwang4 提交于 2022-11-09 14:04 +08:00 . chore: 新增接口说明
module.exports = {
parser: '@typescript-eslint/parser',
plugins: ['jsx-control-statements', '@typescript-eslint'],
rules: {
'react/jsx-no-undef': [2, { allowGlobals: true }],
'@typescript-eslint/no-explicit-any': 'off', // 允许使用 any
'jsx-control-statements/jsx-use-if-tag': 'off', // 可以使用3元运算符
'jsx-control-statements/jsx-jcs-no-undef': 'off', // 关闭自定义类型文件 d.ts 还提示报错问题
'@typescript-eslint/no-unused-vars': 'off', // 关闭变量引入或定义后没有使用时的的报错
'react-hooks/exhaustive-deps': 'off', // 关闭 useEffect 空数组时的报错
},
extends: ['react-app', 'plugin:jsx-control-statements/recommended'],
settings: {
'import/resolver': {
alias: {
map: [
['@', './src'], //别名路径
],
},
},
},
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
JavaScript
1
https://gitee.com/whf293/tmt-web.git
git@gitee.com:whf293/tmt-web.git
whf293
tmt-web
TMT-web
master

搜索帮助