-
Notifications
You must be signed in to change notification settings - Fork 1
/
.eslintrc.js
34 lines (34 loc) · 1.06 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
module.exports = {
root: true,
extends: ["universe/native"],
plugins: ["react-hooks"],
rules: {
"@typescript-eslint/no-unused-vars": "error",
"react-hooks/rules-of-hooks": "error", // Checks rules of Hooks
"react-hooks/exhaustive-deps": "error", // Checks effect dependencies
"prettier/prettier": "error",
"import/order": "error",
"no-restricted-syntax": [
"error",
{
message:
"Do not use StyleSheet.create, it breaks type safety and allows for dead code.\nNo it's not faster, see https://stackoverflow.com/a/56219676\nIf you want to declare constant styles for memoized components, use something like `const myStyle: ViewStyle = { ... }`",
selector:
"MemberExpression[object.name='StyleSheet'][property.name='create']",
},
],
},
overrides: [
{
extends: "universe/node",
files: [
".eslintrc.js",
"babel.config.js",
"electron-webpack.js",
"metro.config.js",
"electron/main/**",
"packages/scripts/**",
],
},
],
};