forked from i18next/next-i18next
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.json
147 lines (147 loc) · 3.52 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
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
{
"parser": "@typescript-eslint/parser",
"plugins": [
"@typescript-eslint",
"eslint-plugin-import",
"typescript-sort-keys",
"prefer-arrow"
],
"extends": [
"eslint:recommended",
"plugin:react/recommended",
"plugin:@typescript-eslint/recommended",
"plugin:jest/recommended",
"plugin:jest/style",
"plugin:typescript-sort-keys/recommended"
],
"ignorePatterns": [
"**/node_modules/*",
"**/out/*",
"**/.next/*",
"**/*package.json"
],
"rules": {
"comma-dangle": [
"error",
"always-multiline"
],
"eol-last": ["error", "always"],
"indent": ["error", 2],
"jest/no-conditional-expect": 0,
"no-console": 2,
"no-trailing-spaces": 2,
"max-len": ["error", {
"code": 80,
"comments": 80,
"ignorePattern": "^import\\s.+\\sfrom\\s.+$",
"ignoreStrings": true,
"ignoreTemplateLiterals": true
}],
"multiline-comment-style": ["error", "separate-lines"],
"no-multiple-empty-lines": "error",
"no-multi-spaces": ["error", { "exceptions": { "Property": false } }],
"no-return-await": 2,
"arrow-body-style": ["error", "as-needed"],
"import/no-amd": 2,
"import/no-commonjs": 2,
// "import/no-default-export": 2,
"import/no-namespace": 2,
"import/no-nodejs-modules": 0,
"keyword-spacing": ["error", { "overrides": {} }],
"react/prefer-stateless-function": 2,
"react/prop-types": 0,
"react/jsx-wrap-multilines": ["error", {
"declaration": "parens-new-line",
"assignment": "parens-new-line",
"return": "parens-new-line",
"arrow": "parens-new-line",
"condition": "parens-new-line",
"logical": "parens-new-line",
"prop": "parens-new-line"
}
],
"semi": ["error", "never"],
"sort-keys": 1,
"space-before-blocks": 2,
"@typescript-eslint/explicit-function-return-type": 0,
"@typescript-eslint/explicit-module-boundary-types": 0,
"@typescript-eslint/member-delimiter-style": ["error", {
"multiline": {
"delimiter": "none",
"requireLast": false
},
"singleline": {
"delimiter": "comma",
"requireLast": false
}
}],
"@typescript-eslint/no-explicit-any": 0,
"@typescript-eslint/no-unused-vars": [
2,
{
"argsIgnorePattern": "^_"
}
],
"@typescript-eslint/no-var-requires": 0,
"prefer-arrow/prefer-arrow-functions": [
"error",
{
"disallowPrototype": true,
"singleReturnOnly": false,
"classPropertiesAllowed": false
}
],
"prefer-destructuring": ["error", {"object": true, "array": true}],
"quotes": ["error", "single"],
"quote-props": ["error", "as-needed"],
"jsx-quotes": ["error", "prefer-single"]
},
"overrides": [
{
"files": [
"cypress/**/*"
],
"plugins": [
"cypress"
],
"env": {
"cypress/globals": true
},
"rules": {
"import/no-default-export": 0,
"jest/expect-expect": 0
}
},
{
"files": [
"examples/**/*"
],
"rules": {
"react/react-in-jsx-scope": 0
}
},
{
"files": [
"examples/**/pages/**/*"
],
"rules": {
"import/no-default-export": 0
}
},
{
"files": [
"**/*.config.js"
],
"rules": {
"import/no-commonjs": 0,
"no-undef": 0
}
}
],
"settings": {
"react": {
"pragma": "React",
"version": "16.13.1"
}
}
}