-
Notifications
You must be signed in to change notification settings - Fork 25
/
Copy patheslint.config.js
51 lines (48 loc) · 1023 Bytes
/
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
import js from "@eslint/js"
import promise from "eslint-plugin-promise"
import babelParser from "@babel/eslint-parser"
import eslintPluginPrettierRecommended from 'eslint-plugin-prettier/recommended'
import globals from "globals";
export default [
js.configs.recommended,
eslintPluginPrettierRecommended,
{
plugins: {
promise
},
languageOptions: {
globals: {
...globals.node
},
parser: babelParser,
ecmaVersion: 2020,
parserOptions: {
ecmaFeatures: {
legacyDecorators: true,
jsx: true
},
requireConfigFile: false,
}
},
ignores: [
"build/*",
"dist/*",
"node_modules/*",
".snapshots/*",
"*.min.js"
],
rules: {
"space-before-function-paren": 0,
"import/export": 0,
"promise/catch-or-return": "error",
"no-useless-return": 1,
"camelcase": 1,
},
},
{
files: ["test/*.spec.js"],
rules: {
"no-undef": 0
}
},
];