-
-
Notifications
You must be signed in to change notification settings - Fork 33
Expand file tree
/
Copy patheslint.config.mjs
More file actions
37 lines (36 loc) · 1.3 KB
/
eslint.config.mjs
File metadata and controls
37 lines (36 loc) · 1.3 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
import reactNativeConfig from '@react-native/eslint-config/flat'
import importPlugin from 'eslint-plugin-import'
export default [
...reactNativeConfig,
importPlugin.flatConfigs.errors,
importPlugin.flatConfigs['react-native'],
importPlugin.flatConfigs.typescript,
{
settings: {
react: {
version: '19.0.0',
},
'import/ignore': ['react-native'],
'import/resolver': {
typescript: true,
},
},
rules: {
// eslint-plugin-eslint-comments v3 is incompatible with ESLint v10
// (uses removed context.getSourceCode API). Disable until the plugin is updated.
'eslint-comments/no-aggregating-enable': 'off',
'eslint-comments/no-unlimited-disable': 'off',
'eslint-comments/no-unused-disable': 'off',
'eslint-comments/no-unused-enable': 'off',
// eslint-plugin-react v7 has rules that use removed ESLint v10 APIs
// (context.getFilename / context.getSourceCode). Disable until updated.
'react/jsx-no-undef': 'off',
'react/no-did-mount-set-state': 'off',
'react/no-did-update-set-state': 'off',
'react/no-string-refs': 'off',
// eslint-plugin-react-native v5 uses context.getSourceCode removed in ESLint v10.
// Disable until updated.
'react-native/no-inline-styles': 'off',
},
},
]