-
Notifications
You must be signed in to change notification settings - Fork 2
/
.eslintrc.cjs
39 lines (36 loc) · 1.01 KB
/
.eslintrc.cjs
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
module.exports = {
parser: '@typescript-eslint/parser',
parserOptions: {
ecmaVersion: 2020,
sourceType: 'module',
},
extends: [
'plugin:@typescript-eslint/recommended', // uses the recommended rules from the @typescript-eslint/eslint-plugin
'prettier', // disable ESLint rules from @typescript-eslint/eslint-plugin that would conflict with prettier
],
ignorePatterns: ["**/docs", "**/dist", "*.test.ts", "*.test.tsx", "./packages/snapps"],
rules: {
// add rules... or dont...
'no-debugger': 'error',
'@typescript-eslint/ban-ts-comment': [
'error',
{'ts-ignore': 'allow-with-description'},
],
'@typescript-eslint/no-explicit-any': 'off',
// todo turn these on
'@typescript-eslint/no-non-null-assertion': 'off',
'@typescript-eslint/no-non-null-asserted-optional-chain': 'off',
'@typescript-eslint/no-empty-function': 'error',
"@typescript-eslint/no-unused-vars": [
"error",
{
"varsIgnorePattern": "^(h|jsx|_)$"
}
],
},
settings: {
"preact": {
"pragma": "h"
}
}
};