-
Notifications
You must be signed in to change notification settings - Fork 122
/
Copy path.eslintrc.json
99 lines (99 loc) · 2.68 KB
/
.eslintrc.json
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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
{
"root": true,
"extends": [
"next/core-web-vitals",
"airbnb",
"airbnb-typescript",
"prettier",
"plugin:prettier/recommended"
],
"plugins": ["testing-library", "@typescript-eslint", "prettier", "vitest"],
"parser": "@typescript-eslint/parser",
"overrides": [
{
"files": ["src/**/*.test.[jt]sx?", "src/**/*.test-d.[jt]sx?"],
"plugins": ["vitest"],
"extends": ["plugin:vitest/recommended"]
},
{
"files": ["functions/**/*"],
"parserOptions": {
"project": "./functions/tsconfig.json"
}
}
],
"parserOptions": {
"project": "./tsconfig.json"
},
"ignorePatterns": [
"next.config.js",
"deploy/**/*",
"src/**/*.test.tsx",
"src/**/*.test.ts",
"src/**/*.test-d.ts",
"playwright/**/*.ts"
],
"rules": {
"react/react-in-jsx-scope": "off",
"react/jsx-props-no-spreading": "off",
"react/jsx-filename-extension": [1, { "extensions": [".tsx", ".jsx"] }],
"import/extensions": [
"error",
"ignorePackages",
{
"js": "never",
"jsx": "never",
"ts": "never",
"tsx": "never"
}
],
"no-console": "off",
"no-restricted-syntax": [
"error",
{
"selector": "CallExpression[callee.object.name='console'][callee.property.name!=/^(log|warn|error|info|trace)$/]",
"message": "Unexpected property on console object was called"
},
{
"selector": "*[value=/\\b(0x)?[a-f0-9]{64}\\b/i]",
"message": "No private keys allowed"
}
],
"prettier/prettier": "error",
"import/prefer-default-export": "off",
"no-underscore-dangle": "off",
"@typescript-eslint/naming-convention": [
"error",
{
"selector": "default",
"format": ["camelCase", "UPPER_CASE", "PascalCase"],
"leadingUnderscore": "allow",
"trailingUnderscore": "allow"
},
{
"selector": "variable",
"format": ["camelCase", "UPPER_CASE", "PascalCase"],
"leadingUnderscore": "allow",
"trailingUnderscore": "allow"
},
{
"selector": "property",
"format": ["camelCase", "UPPER_CASE", "PascalCase"],
"leadingUnderscore": "allowSingleOrDouble",
"trailingUnderscore": "allow"
},
{
"selector": "typeLike",
"format": ["PascalCase"]
}
],
"radix": "off",
"consistent-return": "off",
"jsx-a11y/anchor-is-valid": "off",
"no-return-assign": "off",
"react/require-default-props": "off",
"react/function-component-definition": "off",
"react/no-unstable-nested-components": ["off", { "allowAsProps": true }],
"react/jsx-no-useless-fragment": "off"
}
}