-
Notifications
You must be signed in to change notification settings - Fork 6
/
.eslintrc.js
48 lines (48 loc) · 1.35 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
module.exports = {
parserOptions: {
ecmaVersion: 2020,
sourceType: "module",
ecmaFeatures: {
jsx: true,
},
},
env: {
jasmine: true,
jest: true,
},
extends: [
// NOTE: Due to problem with package dependencies, each package dependency had to be
// manually saved to this project's dependencies.
"@react-native-community",
],
rules: {
"@typescript-eslint/ban-ts-comment": "off",
"@typescript-eslint/no-explicit-any": "off",
"@typescript-eslint/no-unused-vars": [
"warn",
{ varsIgnorePattern: "styles" },
],
"@typescript-eslint/explicit-function-return-type": "off", // Disable for all files (enable for TS)
curly: "off",
"no-console": "warn",
"prettier/prettier": "warn",
"prefer-const": "warn",
quotes: ["warn", "double"], // specify whether double or single quotes should be used
"react/display-name": "off",
"react-native/no-color-literals": "warn",
"react-native/no-inline-styles": "off",
// TODO: Determine if this rule is working
"react-native/no-unused-styles": "warn",
},
overrides: [
// TypeScript overrides
{
files: ["*.ts", "*.tsx"],
rules: {
"@typescript-eslint/explicit-function-return-type": "warn",
"@typescript-eslint/no-shadow": ["warn"],
"no-shadow": "off",
},
},
],
};