forked from newscorp-ghfb/NewsKit
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.base.json
94 lines (91 loc) · 2.39 KB
/
.eslintrc.base.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
{
"root": true,
"ignorePatterns": ["**/*"],
"plugins": ["@nrwl/nx"],
"settings": {
"next": {
"rootDir": "site/"
}
},
"env": {
"jest": true
},
"globals": {
"page": true,
"browser": true,
"context": true,
"cy": true,
"Cypress": true,
"window": true
},
"overrides": [
{
"files": ["*.ts", "*.tsx", "*.js", "*.jsx"],
"rules": {
"@nrwl/nx/enforce-module-boundaries": "off",
"eslint-comments/no-unused-disable": "off"
}
},
{
"files": ["*.tsx"],
"extends": ["plugin:@next/next/recommended"],
"rules": {
"react/prop-types": "off",
"react/forbid-prop-types": "error",
"react-hooks/exhaustive-deps": "warn",
"react/jsx-props-no-spreading": "off",
"react/require-default-props": "off",
"react/jsx-no-useless-fragment": "off",
"react-hooks/rules-of-hooks": "warn",
"react/display-name": "off",
"react/jsx-key": "off"
}
},
{
"files": ["*.ts", "*.tsx"],
"extends": ["plugin:@nrwl/nx/typescript", "plugin:prettier/recommended", "prettier"],
"rules": {
"no-undef": "off",
"no-var": "off",
"no-console": "warn",
"func-names": "warn",
"@typescript-eslint/ban-types": "off",
"@typescript-eslint/no-empty-function": "off",
"@typescript-eslint/ban-ts-comment": "off",
"@typescript-eslint/no-this-alias": "off",
"@typescript-eslint/no-non-null-assertion": "off",
"@typescript-eslint/no-empty-interface": "off",
"@typescript-eslint/no-unused-expressions": "warn",
"@typescript-eslint/no-explicit-any": "off",
"@typescript-eslint/no-inferrable-types": "off",
"@typescript-eslint/no-var-require": "off",
"@typescript-eslint/no-var-requires": "off",
"prettier/prettier": [
"error",
{
"singleQuote": true,
"trailingComma": "all",
"bracketSpacing": false,
"arrowParens": "avoid"
}
]
}
},
{
"files": ["*.js", "*.jsx"],
"extends": ["plugin:@nrwl/nx/javascript"],
"rules": {
"no-undef": "off"
}
},
{
"files": ["*.spec.ts", "*.spec.tsx", "*.test.js", "*.test.jsx"],
"env": {
"jest": true
},
"rules": {
"no-var": "off"
}
}
]
}