Skip to content

Commit 9e6e62c

Browse files
feat: add settings
1 parent 35949cf commit 9e6e62c

File tree

2 files changed

+162
-0
lines changed

2 files changed

+162
-0
lines changed

.editorconfig

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
root = true
2+
3+
[*]
4+
charset = utf-8
5+
end_of_line = lf
6+
insert_final_newline = true
7+
trim_trailing_whitespace = true
8+
indent_style = tab
9+
indent_size = 4
10+
11+
[{*.json,*.yml}]
12+
indent_style = space
13+
indent_size = 2

.eslintrc

Lines changed: 149 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,149 @@
1+
{
2+
"extends": [
3+
"eslint:recommended",
4+
"plugin:@typescript-eslint/recommended",
5+
"plugin:@typescript-eslint/eslint-recommended"
6+
],
7+
"plugins": [
8+
"@typescript-eslint"
9+
],
10+
"parser": "@typescript-eslint/parser",
11+
"parserOptions": {
12+
"sourceType": "module",
13+
"ecmaVersion": 2018
14+
},
15+
"env": {
16+
"node": true,
17+
"jest": true,
18+
"es6": true,
19+
"browser": true
20+
},
21+
"settings": {
22+
"react": {
23+
"version": "latest"
24+
}
25+
},
26+
"rules": {
27+
"camelcase": [
28+
"error",
29+
{
30+
"properties": "always"
31+
}
32+
],
33+
"require-jsdoc": [
34+
"error",
35+
{
36+
"require": {
37+
"FunctionDeclaration": true,
38+
"MethodDefinition": true,
39+
"ClassDeclaration": true
40+
}
41+
}
42+
],
43+
"valid-jsdoc": [
44+
"error",
45+
{
46+
"requireReturn": false,
47+
"preferType": {
48+
"String": "string",
49+
"Object": "object",
50+
"Number": "number",
51+
"Function": "function",
52+
"Void": "void"
53+
}
54+
}
55+
],
56+
"quotes": [
57+
"error",
58+
"single",
59+
"avoid-escape"
60+
],
61+
"key-spacing": [
62+
"error",
63+
{
64+
"singleLine": {
65+
"beforeColon": false,
66+
"afterColon": true
67+
},
68+
"multiLine": {
69+
"beforeColon": false,
70+
"afterColon": true
71+
}
72+
}
73+
],
74+
"no-magic-numbers": [
75+
"error",
76+
{
77+
"ignoreArrayIndexes": true
78+
}
79+
],
80+
"eqeqeq": "error",
81+
"block-scoped-var": "error",
82+
"complexity": [
83+
"error",
84+
{
85+
"maximum": 20
86+
}
87+
],
88+
"curly": "error",
89+
"default-case": "error",
90+
"dot-location": [
91+
"error",
92+
"property"
93+
],
94+
"guard-for-in": "error",
95+
"no-eval": "error",
96+
"block-spacing": "error",
97+
"brace-style": "error",
98+
"comma-spacing": [
99+
"error",
100+
{
101+
"before": false,
102+
"after": true
103+
}
104+
],
105+
"id-length": [
106+
"error",
107+
{
108+
"min": 2,
109+
"properties": "never",
110+
"exceptions": [
111+
"$"
112+
]
113+
}
114+
],
115+
"indent": [
116+
"error",
117+
"tab",
118+
{
119+
"MemberExpression": "off"
120+
}
121+
],
122+
"space-before-function-paren": [
123+
"error",
124+
"never"
125+
],
126+
"space-before-blocks": "error",
127+
"prefer-const": "error",
128+
"no-var": "error",
129+
"arrow-body-style": "off",
130+
"arrow-spacing": "error",
131+
"strict": [
132+
"error"
133+
],
134+
"no-warning-comments": [
135+
"warn",
136+
{
137+
"terms": [
138+
"todo",
139+
"fixme",
140+
"hack"
141+
],
142+
"location": "anywhere"
143+
}
144+
],
145+
"semi": [
146+
"error"
147+
]
148+
}
149+
}

0 commit comments

Comments
 (0)