Linting
This commit is contained in:
@@ -1,3 +1,62 @@
|
||||
{
|
||||
"extends": "next/core-web-vitals"
|
||||
"plugins": ["unused-imports", "@typescript-eslint"],
|
||||
"extends": ["next/core-web-vitals", "plugin:@typescript-eslint/recommended"],
|
||||
"parserOptions": {
|
||||
"project": ["./tsconfig.json", "./tsconfig.test.json"],
|
||||
"extraFileExtensions": [".json"]
|
||||
},
|
||||
"rules": {
|
||||
"@typescript-eslint/no-non-null-assertion": "error",
|
||||
"no-trailing-spaces": "error",
|
||||
"no-unused-vars": "off",
|
||||
"unused-imports/no-unused-imports": "error",
|
||||
"unused-imports/no-unused-vars": "off",
|
||||
"@typescript-eslint/no-unused-vars": [
|
||||
"error",
|
||||
{ "args": "after-used", "argsIgnorePattern": "^_$" }
|
||||
],
|
||||
"@typescript-eslint/no-explicit-any": "error",
|
||||
"@typescript-eslint/member-delimiter-style": [
|
||||
"error",
|
||||
{
|
||||
"multiline": {
|
||||
"delimiter": "none",
|
||||
"requireLast": false
|
||||
},
|
||||
"singleline": {
|
||||
"delimiter": "comma",
|
||||
"requireLast": false
|
||||
}
|
||||
}
|
||||
],
|
||||
"@typescript-eslint/semi": ["error", "never"],
|
||||
"no-shadow": "off",
|
||||
"@typescript-eslint/no-shadow": ["error"],
|
||||
"no-useless-constructor": "off",
|
||||
"no-use-before-define": "off",
|
||||
"jsx-a11y/label-has-associated-control": "error",
|
||||
"no-console": ["error", { "allow": ["warn", "error"] }],
|
||||
"indent": [2, 2],
|
||||
"new-cap": ["error", { "capIsNewExceptions": ["Router"] }],
|
||||
"semi": ["error", "never"],
|
||||
"multiline-ternary": "off",
|
||||
"quotes": ["error", "single", { "avoidEscape": true }],
|
||||
"jsx-quotes": ["error", "prefer-single"],
|
||||
"no-return-await": "error",
|
||||
"no-process-env": "error",
|
||||
"react-hooks/exhaustive-deps": [
|
||||
"warn",
|
||||
{
|
||||
"additionalHooks": "(useAsyncEffect)"
|
||||
}
|
||||
]
|
||||
},
|
||||
"overrides": [
|
||||
{
|
||||
"files": "**/*.js",
|
||||
"rules": {
|
||||
"@typescript-eslint/no-var-requires": ["off"]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user