litmus/litmus-portal/frontend/.eslintrc.json

86 lines
2.0 KiB
JSON

{
"parser": "@typescript-eslint/parser",
"plugins": ["@typescript-eslint"],
"extends": [
"airbnb",
"plugin:prettier/recommended",
"plugin:jest/recommended",
"prettier/react"
],
"env": {
"browser": true,
"es6": true
},
"settings": {
"import/extensions": [".js", ".jsx", ".ts", ".tsx"],
"import/parsers": {
"@typescript-eslint/parser": [".ts", ".tsx"]
},
"import/resolver": {
"node": {
"extensions": [".js", ".jsx", ".ts", ".tsx"]
}
}
},
"rules": {
"new-cap": 0,
"no-underscore-dangle": 0,
"react/static-property-placement": [
"warn",
"property assignment",
{ "defaultProps": "static public field" }
],
"import/prefer-default-export": 0,
"lines-between-class-members": 0,
"no-restricted-syntax": 0,
"no-nested-ternary": 0,
"no-plusplus": 0,
"dot-notation": 0,
"camelcase": 0,
"jsx-a11y/anchor-is-valid": 0,
"jsx-a11y/href-no-hash": ["off"],
"react/jsx-props-no-spreading": ["off"],
"react/jsx-filename-extension": [
"warn",
{ "extensions": [".js", ".jsx", ".ts", ".tsx"] }
],
"no-console": [
"error",
{
"allow": ["warn", "error"]
}
],
"multiline-ternary": 0,
"no-unused-vars": "off",
"no-shadow": 0,
"@typescript-eslint/no-unused-vars": "error",
"no-useless-constructor": "off",
"@typescript-eslint/no-useless-constructor": "error",
"react/prop-types": 0,
"import/extensions": [
"error",
"ignorePackages",
{
"js": "never",
"jsx": "never",
"ts": "never",
"tsx": "never"
}
],
"max-len": [
"warn",
{
"code": 100,
"tabWidth": 2,
"comments": 100,
"ignoreComments": false,
"ignoreTrailingComments": true,
"ignoreUrls": true,
"ignoreStrings": true,
"ignoreTemplateLiterals": true,
"ignoreRegExpLiterals": true
}
]
}
}