forked from ShelterTechSF/askdarcel-web
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.js
44 lines (43 loc) · 1.3 KB
/
.eslintrc.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
/* eslint-disable */
const path = require("path");
module.exports = {
root: true,
extends: [
"eslint:recommended",
"plugin:import/recommended",
"prettier",
"react-app",
"react-app/jest",
"plugin:jsx-a11y/recommended",
"plugin:import/typescript",
"plugin:@typescript-eslint/recommended",
],
plugins: ["react", "jsx-a11y", "import", "@typescript-eslint"],
parser: "@typescript-eslint/parser",
parserOptions: { project: ["./tsconfig.json"] },
env: {
browser: true,
},
settings: {
"import/resolver": {
node: {
extensions: [".js", ".jsx", ".ts", ".tsx"],
paths: [path.resolve(__dirname, "app")],
},
},
},
ignorePatterns: ["coverage"],
rules: {
"import/no-extraneous-dependencies": ["error", { devDependencies: true }],
"import/no-named-as-default": 0,
"jsx-a11y/label-has-associated-control": ["error", { assert: "either" }],
"no-console": "warn",
"react-hooks/exhaustive-deps": "error", // Default is 'warn'; we upgrade to 'error' because otherwise warnings are just noise
"react/jsx-filename-extension": ["error", { extensions: [".tsx"] }],
"react/function-component-definition": [
"error",
{ namedComponents: "arrow-function" },
],
"@typescript-eslint/ban-ts-comment": "warn",
},
};