/
.eslintrc.cjs
46 lines (46 loc) · 831 Bytes
/
.eslintrc.cjs
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
/** @type {import("eslint").Linter.Config} */
module.exports = {
env: {
browser: true,
node: true,
'vitest-globals/env': true,
},
extends: [
'plugin:jsx-a11y/recommended',
'plugin:react/recommended',
'plugin:react/jsx-runtime',
'prettier',
'plugin:vitest-globals/recommended',
],
plugins: ['import'],
parserOptions: {
ecmaFeatures: { jsx: true },
ecmaVersion: 'latest',
sourceType: 'module',
},
rules: {
'import/order': [
'warn',
{
alphabetize: { order: 'asc' },
groups: [
'external',
'builtin',
'internal',
'parent',
'sibling',
'index',
],
},
],
'react/jsx-filename-extension': [1, { allow: 'as-needed' }],
'react/jsx-sort-props': [
1,
{
callbacksLast: true,
reservedFirst: true,
},
],
'react/prop-types': 'off',
},
};