-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.eslintrc.json
69 lines (69 loc) · 2.44 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
{
"env": {
"es2021": true,
"node": true,
"jest": true
},
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended",
"plugin:prettier/recommended",
"prettier/prettier",
"plugin:import/recommended"
],
"parser": "@typescript-eslint/parser",
"parserOptions": {
"project": ["./tsconfig.json", "./jest.config.js"],
"ecmaVersion": "latest",
"sourceType": "module"
},
"plugins": ["@typescript-eslint", "prettier"],
"rules": {
"camelcase": "error",
"comma-dangle": ["error", "always-multiline"],
"no-console": ["warn"],
"@typescript-eslint/no-var-requires": "off",
"no-constant-condition": ["error", { "checkLoops": true }],
"no-restricted-syntax": [
"error",
{
"selector": "LabeledStatement",
"message": "Labels are a form of GOTO; using them makes code confusing and hard to maintain and understand."
},
{
"selector": "WithStatement",
"message": "`with` is disallowed in strict mode because it makes code impossible to predict and optimize."
}
],
"no-use-before-define": ["off", { "functions": false }],
"no-unused-expressions": ["error", { "allowTaggedTemplates": true }],
"prefer-const": [
"error",
{ "destructuring": "all" }
],
"prefer-destructuring": ["error", { "array": false, "object": false }, { "enforceForRenamedProperties": true }],
"spaced-comment": ["error", "always"],
"import/extensions": ["error", "never"],
"import/no-unresolved": "off",
"import/order": [
"error",
{
"groups": [
"builtin",
"external",
"internal",
"parent",
"sibling"
],
"newlines-between": "always",
"alphabetize": {
"order": "asc",
"caseInsensitive": false
}
}
],
"import/prefer-default-export": "off"
},
"ignorePatterns": ["dist/", "node_modules/", "jest.config.js", "babel.config.js", "__test__"]
}