-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.eslintrc.js
More file actions
67 lines (67 loc) · 1.58 KB
/
.eslintrc.js
File metadata and controls
67 lines (67 loc) · 1.58 KB
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
61
62
63
64
65
66
67
module.exports = {
parser: '@typescript-eslint/parser',
env: {
node: true,
},
extends: [
'airbnb-typescript',
'eslint:recommended',
'plugin:import/errors',
'plugin:import/warnings',
'plugin:import/typescript',
'prettier'
],
plugins: ['import'],
// parser: "@babel/eslint-parser",
parserOptions: {
ecmaVersion: 2020,
sourceType: 'module',
ecmaFeatures: {
jsx: true,
},
project: ['./tsconfig.json'],
"requireConfigFile": false,
"babelOptions": {
parserOpts: {
plugins: ["jsx"]
},
"presets": ["@babel/preset-react"]
},
},
settings: {
'import/parsers': {
'@typescript-eslint/parser': ['.ts'],
},
'import/resolver': {
node: {
extensions: ['.js', '.jsx', '.ts', '.tsx'],
moduleDirectory: ['node_modules', 'src/'],
},
typescript: {
alwaysTryTypes: true,
project: '.',
},
},
},
rules: {
"no-unused-vars": "warn",
'import/no-named-default': 'warn',
'no-empty': 'warn',
'import/no-named-as-default-member': 'warn',
'@typescript-eslint/no-shadow': 'warn',
'@typescript-eslint/no-throw-literal': 'warn',
'@typescript-eslint/ban-types': 'warn',
'@typescript-eslint/no-empty-interface': 'warn',
"import/imports-first": ["error", "absolute-first"],
},
"globals": {
"window": true,
"document": true,
"localStorage": true,
"FormData": true,
"FileReader": true,
"Blob": true,
"navigator": true
},
ignorePatterns: ['**/*.js', 'node_modules', '.turbo', 'dist', 'coverage'],
}