-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy patheslint.config.mjs
45 lines (42 loc) · 1.21 KB
/
eslint.config.mjs
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
import globals from "globals";
import js from "@eslint/js";
import stylistic from "@stylistic/eslint-plugin";
export default [
js.configs.recommended,
{ ignores: ["*.config.*"] },
{
plugins: {
'@stylistic': stylistic
},
languageOptions: {
globals: {
...globals.browser,
...globals.node,
},
ecmaVersion: "latest",
sourceType: "module",
},
rules: {
"@stylistic/max-len": [1, 120, 2, { "ignoreComments": true }],
"no-unused-vars": "warn",
"no-console": "off",
"@stylistic/comma-dangle": ["warn", "only-multiline"],
"@stylistic/semi": ["warn", "always"],
"@stylistic/quotes": [2, "single",
{
allowTemplateLiterals: true,
avoidEscape: true,
},
],
"camelcase": ["error", {"properties": "always"}],
"dot-notation": "warn",
"@stylistic/space-before-function-paren": "off",
"@stylistic/indent": ["warn", 2],
"@stylistic/padded-blocks": "off",
"@stylistic/no-trailing-spaces": "warn",
"@stylistic/array-bracket-spacing": "warn",
"@stylistic/no-multi-spaces": ["error", { "ignoreEOLComments": true }],
"no-var": "error",
},
},
];