-
Notifications
You must be signed in to change notification settings - Fork 13
Expand file tree
/
Copy patheslint.config.js
More file actions
51 lines (50 loc) · 1.29 KB
/
eslint.config.js
File metadata and controls
51 lines (50 loc) · 1.29 KB
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
import pluginJs from "@eslint/js";
import stylistic from '@stylistic/eslint-plugin'
import tseslint from "typescript-eslint";
export default tseslint.config(
pluginJs.configs.recommended,
tseslint.configs.recommended,
{
plugins: {
'@stylistic': stylistic
},
files: ["src/**/*.{js,mjs,cjs,ts}", "test/**/*.{js,mjs,cjs,ts}"],
rules: {
'@stylistic/indent': [
'error',
2,
{
SwitchCase: 1,
ignoredNodes: [
'FunctionExpression > .params[decorators.length > 0]',
'FunctionExpression > .params > :matches(Decorator, :not(:first-child))',
'ClassBody.body > PropertyDefinition[decorators.length > 0] > .key',
],
},
],
'@stylistic/linebreak-style': [
'error',
'unix'
],
'@stylistic/max-len': [
'error',
{
code: 120,
ignoreComments: true
}
],
'@stylistic/quotes': [
'error',
'single'
],
'@stylistic/semi': [
'error',
'always'
],
'@typescript-eslint/explicit-module-boundary-types': ['error'],
'@stylistic/keyword-spacing': ['error'],
'@stylistic/space-before-blocks': ['error'],
'@stylistic/space-infix-ops': ['error']
},
},
);