Skip to content

Commit e4432bb

Browse files
authored
Update eslint (#642)
1 parent 6c32621 commit e4432bb

File tree

5 files changed

+283
-363
lines changed

5 files changed

+283
-363
lines changed

Diff for: .eslintignore

-4
This file was deleted.

Diff for: .eslintrc.json

-35
This file was deleted.

Diff for: eslint.config.mjs

+47
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
import js from '@eslint/js';
2+
import mocha from 'eslint-plugin-mocha';
3+
import globals from 'globals';
4+
5+
export default [
6+
{
7+
ignores: [
8+
//
9+
'**/elm-stuff',
10+
'**/fixtures',
11+
'**/templates',
12+
'**/flow-typed',
13+
],
14+
},
15+
{
16+
rules: {
17+
...js.configs.recommended.rules,
18+
'no-inner-declarations': 'off',
19+
'no-prototype-builtins': 'off',
20+
'no-unused-vars': ['error', { caughtErrorsIgnorePattern: '^_' }],
21+
},
22+
languageOptions: {
23+
globals: {
24+
...globals.node,
25+
},
26+
},
27+
},
28+
{
29+
files: ['tests/*'],
30+
plugins: {
31+
mocha,
32+
},
33+
languageOptions: {
34+
globals: {
35+
...globals.mocha,
36+
},
37+
},
38+
rules: {
39+
'mocha/handle-done-callback': 'error',
40+
'mocha/no-exclusive-tests': 'error',
41+
'mocha/no-exports': 'error',
42+
'mocha/no-identical-title': 'error',
43+
'mocha/no-nested-tests': 'error',
44+
'mocha/no-skipped-tests': 'error',
45+
},
46+
},
47+
];

0 commit comments

Comments
 (0)