-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.eslintrc.js
73 lines (73 loc) · 2.35 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
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
module.exports = {
root: true,
extends: ["airbnb-base", "airbnb-typescript/base", "plugin:prettier/recommended"],
parser: "@typescript-eslint/parser",
parserOptions: {
project: ["./tsconfig.eslint.json"],
},
settings: {
"import/parsers": {
"@typescript-eslint/parser": [".ts", ".tsx"],
},
"import/resolver": {
typescript: {},
},
},
rules: {
"max-len": ["error", 120, 4],
"import/extensions": [
"error",
"ignorePackages",
{
js: "never",
jsx: "never",
ts: "never",
tsx: "never",
},
],
camelcase: [
"error",
{
properties: "always",
ignoreDestructuring: false,
ignoreImports: false,
ignoreGlobals: false,
},
],
"import/no-extraneous-dependencies": ["error", { devDependencies: true }],
"class-methods-use-this": "off",
"import/prefer-default-export": "off",
"no-param-reassign": "off",
"no-console": process.env.NODE_ENV === "production" ? "warn" : "off",
"no-debugger": process.env.NODE_ENV === "production" ? "warn" : "off",
"operator-linebreak": "off",
"object-curly-newline": [
"error",
{
ObjectExpression: { consistent: true },
ObjectPattern: { consistent: true },
ImportDeclaration: { consistent: true },
ExportDeclaration: { consistent: true },
},
],
"implicit-arrow-linebreak": "off",
"function-paren-newline": "off",
"prefer-template": "off",
"no-underscore-dangle": "off",
"no-plusplus": "off",
"@typescript-eslint/quotes": ["error", "double", { allowTemplateLiterals: true }],
"@typescript-eslint/indent": "off",
"@typescript-eslint/lines-between-class-members": "off",
"@typescript-eslint/no-empty-function": "off",
"@typescript-eslint/explicit-function-return-type": ["error"],
},
overrides: [
{
files: ["test/**/*.?(e2e-)spec.{j,t}s?(x)"],
env: {
jest: true,
},
},
],
ignorePatterns: ["lib/*", "node_modules/*"],
};