-
Notifications
You must be signed in to change notification settings - Fork 3
/
.eslintrc.json
33 lines (33 loc) · 919 Bytes
/
.eslintrc.json
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
{
"extends": [
"eslint:recommended",
"plugin:react/recommended",
"plugin:react-hooks/recommended"
],
"parserOptions": {
"ecmaVersion": 2021,
"sourceType": "module",
"ecmaFeatures": {
"jsx": true
}
},
"env": {
"browser": true,
"node": true,
"es2021": true
},
"rules": {
"semi": ["error", "always"], // Enforce semicolons at the end of statements
"quotes": ["error", "double"], // Enforce double quotes for strings
"indent": ["error", 2], // Enforce 2 spaces for indentation
"no-console": "warn", // Warn when using console.log
"react/jsx-props-no-spreading": "off", // Allow spreading of props in JSX
"react-hooks/rules-of-hooks": "error", // Enforce rules of React Hooks
"react-hooks/exhaustive-deps": "warn" // Warn about missing dependencies in useEffect
},
"settings": {
"react": {
"version": "detect"
}
}
}