-
Notifications
You must be signed in to change notification settings - Fork 2
/
.eslintrc.js
55 lines (55 loc) · 1.42 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
module.exports = {
extends: [
'@react-native',
'airbnb-typescript',
'prettier',
],
parser: '@typescript-eslint/parser',
parserOptions: {
sourceType: 'module',
ecmaVersion: 2020,
ecmaFeatures: {
jsx: true,
},
project: './tsconfig.json',
tsconfigRootDir: __dirname,
},
plugins: ['react', 'react-native', 'jest', 'import', 'react-hooks'],
env: {
'react-native/react-native': true,
},
rules: {
'global-require': 0,
'react/jsx-filename-extension': [1, { extensions: ['.ts', '.tsx'] }],
'react/prop-types': 'off',
'react/require-default-props': [2, { ignoreFunctionalComponents: true }],
'react-native/no-unused-styles': 2,
'react-native/no-inline-styles': 2,
'react-native/no-color-literals': 2,
'no-trailing-spaces': ['error'],
'no-multiple-empty-lines': ['error'],
'no-use-before-define': 'off',
'@typescript-eslint/no-use-before-define': [
'error',
{ functions: true, classes: true, variables: false },
],
'no-unused-vars': 'off',
'@typescript-eslint/no-unused-vars': ['error'],
'@typescript-eslint/default-param-last': 1,
"import/no-extraneous-dependencies": [
"error",
{
"devDependencies": ["mockserver/**"],
}
],
},
ignorePatterns: [
'.eslintrc.js',
'babel.config.js',
'metro.config.js',
'jest.config.js',
'e2e/*',
'node_modules/',
],
root: true,
};