forked from redstone-finance/redstone-oracles-monorepo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.js
60 lines (60 loc) · 1.89 KB
/
.eslintrc.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
module.exports = {
extends: [
"eslint:recommended",
"plugin:import/recommended",
"plugin:import/typescript",
"plugin:@typescript-eslint/recommended-type-checked",
"plugin:prettier/recommended",
"plugin:workspaces/recommended",
],
parser: "@typescript-eslint/parser",
plugins: ["@typescript-eslint", "workspaces", "eslint-plugin-import"],
// for some reason eslint hangs on "artifacts" directory
ignorePatterns: ["artifacts", "dist", "*.js", "*.mjs", "!.jest"],
settings: {
"import/resolver": {
typescript: true,
node: true,
},
},
rules: {
"@typescript-eslint/no-floating-promises": "error",
"@typescript-eslint/no-unnecessary-condition": "error",
"no-constant-condition": "off",
"no-unused-expressions": "off",
"@typescript-eslint/no-unused-expressions": "error",
"no-return-await": "off",
"class-methods-use-this": "off",
"@typescript-eslint/class-methods-use-this": [
"error",
{
ignoreOverrideMethods: true,
},
],
"@typescript-eslint/return-await": ["error", "always"],
"workspaces/require-dependency": "off",
"no-unused-vars": "off",
"@typescript-eslint/no-unused-vars": [
"error",
{ argsIgnorePattern: "^_", varsIgnorePattern: "^_" },
],
"no-loss-of-precision": "off",
"@typescript-eslint/no-loss-of-precision": "error",
"@typescript-eslint/unbound-method": ["error", { ignoreStatic: true }],
"no-throw-literal": "off",
"@typescript-eslint/no-throw-literal": "error",
"prefer-promise-reject-errors": "error",
"import/no-named-as-default": ["off"],
"import/no-named-as-default-member": ["off"],
"import/no-unresolved": [
"error",
{
commonjs: true,
ignore: ["warp-contracts/lib/types/contract/testing/Testing"],
},
],
"import/order": ["off"],
"import/namespace": "off",
},
root: true,
};