-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy patheslint.config.js
60 lines (59 loc) · 1.28 KB
/
eslint.config.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
// @ts-check
import eslint from "@eslint/js"
import ts_eslint from "typescript-eslint"
import functional from "eslint-plugin-functional"
export default ts_eslint.config({
extends: [
eslint.configs.recommended,
...ts_eslint.configs.recommendedTypeChecked,
],
plugins: {
"@typescript-eslint": ts_eslint.plugin,
functional,
},
languageOptions: {
parserOptions: {
project: true,
tsconfigRootDir: import.meta.dirname,
},
},
rules: {
semi: ["error", "never"],
indent: ["error", "tab"],
"no-trailing-spaces": "error",
"no-mixed-spaces-and-tabs": "error",
quotes: [
"error",
"double",
{
allowTemplateLiterals: true,
},
],
"no-console": "error",
"prefer-const": "off",
curly: "error",
"@typescript-eslint/no-this-alias": [
"error",
{
allowedNames: ["me"],
},
],
"@typescript-eslint/await-thenable": "error",
"@typescript-eslint/ban-ts-comment": "off",
"@typescript-eslint/method-signature-style": ["error", "property"],
"functional/immutable-data": [
"error",
{
ignoreClasses: true,
ignoreAccessorPattern: "**.*_m*.**",
ignoreNonConstDeclarations: {
treatParametersAsConst: true,
},
},
],
"@typescript-eslint/no-unused-vars": ["error", {
varsIgnorePattern: "^_",
argsIgnorePattern: "^_"
}]
}
})