-
Notifications
You must be signed in to change notification settings - Fork 16
Expand file tree
/
Copy patheslint.config.js
More file actions
43 lines (41 loc) · 1.26 KB
/
eslint.config.js
File metadata and controls
43 lines (41 loc) · 1.26 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 eslint from '@eslint/js';
import tseslint from 'typescript-eslint';
import mochaPlugin from 'eslint-plugin-mocha';
import { FlatCompat } from '@eslint/eslintrc';
import { baseRules } from '../../eslint.config.base.js';
const compat = new FlatCompat();
export default [
eslint.configs.recommended,
...tseslint.configs.recommended,
...compat.config(mochaPlugin.configs.recommended),
{
files: ['src/**/*.ts', 'test/**/*.ts'],
rules: {
...baseRules,
'unicorn/no-abusive-eslint-disable': 'off',
'@typescript-eslint/no-use-before-define': 'off',
'@typescript-eslint/ban-ts-ignore': 'off',
indent: 'off',
'object-curly-spacing': 'off',
'@typescript-eslint/no-unused-vars': ['error', { argsIgnorePattern: '^_' }],
'mocha/no-async-describe': 'off',
'mocha/no-identical-title': 'off',
'mocha/no-mocha-arrows': 'off',
'mocha/no-setup-in-describe': 'off',
'@typescript-eslint/no-explicit-any': 'off',
'@typescript-eslint/no-var-requires': 'off',
'prefer-const': 'error',
'no-fallthrough': 'error',
'no-prototype-builtins': 'off',
},
},
{
files: ['*.d.ts'],
rules: {
'@typescript-eslint/no-explicit-any': 'off',
},
},
{
ignores: ['lib/**'],
},
];