-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy patheslint.config.mjs
More file actions
43 lines (42 loc) · 1.15 KB
/
eslint.config.mjs
File metadata and controls
43 lines (42 loc) · 1.15 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
import { defineConfig, globalIgnores } from 'eslint/config';
import ts from 'eslint-config-zakodium/ts';
import vitest from 'eslint-config-zakodium/vitest-ts';
export default defineConfig(
globalIgnores(['rest-on-couch/**', 'lib/**']),
ts,
vitest,
{
files: ['**/*.ts'],
rules: {
camelcase: 'off',
'@typescript-eslint/no-dynamic-delete': 'off',
'@typescript-eslint/naming-convention': [
'error',
{ selector: ['typeLike'], format: ['PascalCase'] },
{ selector: ['variable'], format: ['camelCase', 'UPPER_CASE'] },
{ selector: ['function'], format: ['camelCase', 'PascalCase'] },
{
selector: [
'method',
'classProperty',
'classMethod',
'parameterProperty',
'accessor',
'typeProperty',
'typeMethod',
],
format: ['camelCase', 'snake_case'],
leadingUnderscore: 'allow',
},
{
selector: [
'objectLiteralProperty',
'objectLiteralMethod',
'enumMember',
],
format: null,
},
],
},
},
);