-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy patheslint.config.mjs
66 lines (63 loc) · 1.79 KB
/
eslint.config.mjs
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
// @ts-check
import withNuxt from './.nuxt/eslint.config.mjs'
export default withNuxt(
{
rules: {
// @typescript
'@typescript-eslint/naming-convention': 'off',
'@typescript-eslint/comma-dangle': 'off',
'@typescript-eslint/no-use-before-define': 0,
'@typescript-eslint/no-empty-interface': 'off',
'@typescript-eslint/no-explicit-any': 'off',
'@typescript-eslint/consistent-type-imports': 'warn',
'@typescript-eslint/ban-ts-comment': 'off',
'@typescript-eslint/ban-types': 'warn',
'@typescript-eslint/no-empty-function': 'off',
'@typescript-eslint/no-unnecessary-type-constraint': 'warn',
'@typescript-eslint/no-non-null-asserted-optional-chain': 'warn',
'@typescript-eslint/no-var-requires': 'off',
'@typescript-eslint/no-unused-vars': 'off',
'@typescript-eslint/no-this-alias': [
'error',
{
allowedNames: ['_this'],
},
],
// import
'import/order': [
'error',
{
groups: ['builtin', 'external', 'internal', 'parent', 'sibling', 'index'],
pathGroups: [
{
pattern: 'react',
group: 'builtin',
position: 'before',
},
{
pattern: '@/**',
group: 'internal',
},
],
pathGroupsExcludedImportTypes: ['builtin'],
alphabetize: {
order: 'asc',
caseInsensitive: true,
},
},
],
'import/no-anonymous-default-export': 0,
// eslint
'arrow-body-style': 'off',
'no-empty-function': 'off',
'max-lines': [
'error',
{
max: 1000,
skipBlankLines: true,
skipComments: true,
},
],
}
}
)