-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy patheslint.config.mjs
46 lines (44 loc) · 1.09 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
// @ts-check
import eslint from '@eslint/js';
import importPlugin from 'eslint-plugin-import';
import tseslint from 'typescript-eslint';
export default tseslint.config(
eslint.configs.recommended,
// eslint-disable-next-line import/no-named-as-default-member
...tseslint.configs.recommended,
importPlugin.flatConfigs.recommended,
importPlugin.flatConfigs.typescript,
{
languageOptions: {
parserOptions: {
ecmaVersion: 'latest',
sourceType: 'module'
}
},
settings: {
'import/resolver': {
typescript: true,
node: true
}
},
rules: {
'import/order': [
'warn',
{
alphabetize: {
order: 'asc'
}
}
],
'@typescript-eslint/consistent-type-imports': [
'warn',
{ prefer: 'type-imports', fixStyle: 'separate-type-imports' }
],
'import/consistent-type-specifier-style': ['error', 'prefer-top-level'],
'@/quotes': ['error', 'single', { avoidEscape: true, allowTemplateLiterals: false }]
}
},
{
ignores: ['build/']
}
);