{
"extends": [
"airbnb",
"airbnb-typescript",
"plugin:@typescript-eslint/recommended",
"plugin:@typescript-eslint/recommended-requiring-type-checking",
"plugin:eslint-comments/recommended"
],
"plugins": [
"@typescript-eslint",
"eslint-comments",
"react",
"import",
"react-hooks"
],
"globals": {
"console": true,
"window": true
},
"parser": "@typescript-eslint/parser",
"parserOptions": {
"sourceType": "module",
"ecmaFeatures": {
"modules": true,
"jsx": true
},
"project": "./tsconfig.json"
},
"root": true,
"env": {
"browser": true,
"node": true,
"es6": true
},
"settings": {
"import/resolver": {
"node": {
"extensions": [".ts", ".tsx"]
}
}
},
"rules": {
"no-console": "error",
"no-void": ["error", { "allowAsStatement": true }],
"no-bitwise": [1, { "int32Hint": true, "allow": ["~"] }],
"no-plusplus": ["error", { "allowForLoopAfterthoughts": true }],
"react/jsx-fragments": ["error", "element"],
"import/prefer-default-export": 0,
"react/prop-types": 0,
"react/require-default-props": 0,
"react-hooks/rules-of-hooks": "error",
"react-hooks/exhaustive-deps": "warn",
"react/function-component-definition": 0,
"react/style-prop-object": 0,
"no-restricted-exports": 0,
"@typescript-eslint/no-explicit-any": "error",
"max-len": ["error", { "code": 140, "comments": 140 }],
"import/order":
[1,{
"groups": [
"external",
"builtin",
"internal",
"sibling",
"parent",
"index"]
}
],
"no-restricted-syntax": ["error",
{
"selector": "CallExpression[callee.object.name='localStorage']",
"message": "Не используйте localStorage, вместо этого используйте storage из файла storage.ts."
}
]
}
}
"eslint": "^8.43.0",
"eslint-config-airbnb": "^19.0.4",
"eslint-config-airbnb-typescript": "^17.0.0",
"eslint-config-react": "^1.1.7",
"eslint-import-resolver-node": "^0.3.7",
"eslint-plugin-eslint-comments": "^3.2.0",
"eslint-plugin-import": "^2.28.1",
"eslint-plugin-jsx-a11y": "^6.7.1",
"eslint-plugin-react": "^7.32.2",
"eslint-plugin-react-hooks": "^4.6.0",