This repository has been archived by the owner on Sep 17, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy path.eslintrc.js
86 lines (86 loc) · 2.04 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
74
75
76
77
78
79
80
81
82
83
84
85
86
/* eslint-env node */
module.exports = {
parser: "@typescript-eslint/parser",
extends: [
"plugin:react/recommended",
"prettier",
"plugin:prettier/recommended",
"eslint:recommended",
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended",
"plugin:import/typescript",
],
plugins: ["import"],
parserOptions: {
ecmaVersion: 2018,
sourceType: "module",
ecmaFeatures: {
jsx: true,
},
},
rules: {
"no-console": "warn",
"newline-before-return": "error",
"linebreak-style": "off",
"arrow-body-style": "error",
"import/first": "error",
"import/newline-after-import": ["error", { count: 1 }],
"import/order": [
"error",
{
"newlines-between": "always",
pathGroups: [
{
pattern: "react",
group: "builtin",
position: "before",
},
{
pattern: "@numaryhq/storybook",
group: "sibling",
position: "after",
},
{
pattern: "../**",
group: "internal",
position: "before",
},
{
pattern: "^~/src/",
group: "internal",
position: "after",
},
],
pathGroupsExcludedImportTypes: ["react"],
alphabetize: {
order:
"asc" /* sort in ascending order. Options: ['ignore', 'asc', 'desc'] */,
caseInsensitive: true /* ignore case. Options: [true, false] */,
},
},
],
"prettier/prettier": [
"error",
{
endOfLine: "auto",
singleQuote: true,
arrowParens: "always",
trailingComma: "es5",
printWidth: 80,
},
],
"react/prop-types": "off",
"no-unused-vars": "off",
"@typescript-eslint/no-unused-vars": ["warn"],
"@typescript-eslint/no-explicit-any": "off",
},
settings: {
react: {
version: "detect",
},
"import/resolver": {
typescript: true,
node: true,
},
},
};