-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy patheslint.config.mjs
More file actions
51 lines (50 loc) · 1.28 KB
/
eslint.config.mjs
File metadata and controls
51 lines (50 loc) · 1.28 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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
// @ts-check
import eslintConfigPrettier from 'eslint-config-prettier';
import tseslint from 'typescript-eslint';
import eslint from '@eslint/js';
export default tseslint.config(
{ ignores: ['**/node_modules', '**/dist', '**/out', './archive'] },
eslint.configs.recommended,
tseslint.configs.recommended,
{
files: ['**/*.{ts}'],
languageOptions: {
parserOptions: {
parser: tseslint.parser,
},
},
},
{
files: ['**/**.{ts}'],
rules: {
'@typescript-eslint/no-explicit-any': 'off',
'@typescript-eslint/naming-convention': [
'error',
{
format: ['camelCase', 'UPPER_CASE', 'PascalCase'],
leadingUnderscore: 'allow',
selector: 'variable',
},
{
format: ['camelCase', 'PascalCase'],
selector: 'function',
},
{
format: ['camelCase'],
selector: ['objectLiteralProperty', 'typeProperty'],
},
{
format: ['PascalCase'],
selector: ['enum', 'enumMember', 'class', 'interface', 'typeAlias'],
},
{
format: ['camelCase'],
leadingUnderscore: 'require',
modifiers: ['unused'],
selector: 'parameter',
},
],
},
},
eslintConfigPrettier,
);