自分用.eslintrc.js
code:js
module.exports = {
"env": {
"browser": true,
"es6": true
},
"extends": [
"eslint:all",
"plugin:react/recommended",
"plugin:@typescript-eslint/eslint-recommended"
],
"globals": {
"Atomics": "readonly",
"SharedArrayBuffer": "readonly"
},
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaFeatures": {
"jsx": true
},
"ecmaVersion": 2018,
"sourceType": "module"
},
"plugins": [
"react",
"@typescript-eslint"
],
"rules": {
"no-process-env": "off",
"no-use-before-define": "off",
"no-console": "off",
"no-magic-numbers": "off",
"sort-imports": "off",
"id-length": "off",
"no-ternary": "off",
"no-invalid-this": "off",
"multiline-ternary": "off",
"lines-around-comment": "off",
"no-mixed-operators": "off",
"capitalized-comments": "off",
"multiline-comment-style": "off",
"spaced-comment": "off",
"no-unused-vars": ["error", {
"ignoreRestSiblings": true,
"argsIgnorePattern": "^_"
}],
"prefer-object-spread": "off",
"newline-per-chained-call": "off"
}
};