Skip to content

Commit a4632d9

Browse files
build(deps-dev): bump eslint from 8.57.0 to 9.8.0 (#1697)
* build(deps-dev): bump eslint from 8.57.0 to 9.8.0 Bumps [eslint](https://github.com/eslint/eslint) from 8.57.0 to 9.8.0. - [Release notes](https://github.com/eslint/eslint/releases) - [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md) - [Commits](eslint/eslint@v8.57.0...v9.8.0) --- updated-dependencies: - dependency-name: eslint dependency-type: direct:development update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> * feat: eslint 9 * chore: linter check * feat: nolyfill * fix: eslint 9 * fix: linter --------- Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: fengkx <[email protected]>
1 parent a971fc7 commit a4632d9

File tree

10 files changed

+879
-940
lines changed

10 files changed

+879
-940
lines changed

.eslintrc.js

-46
This file was deleted.

.github/workflows/test.yml

+1
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ jobs:
2727
npm cache clean --force
2828
npm ci
2929
npm run build
30+
npm run lint
3031
npm test -- --forceExit #https://github.com/facebook/jest/issues/9982#issuecomment-758110298
3132
env:
3233
CI: true

eslint.config.mjs

+51
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
import tsEslint from 'typescript-eslint';
2+
import globals from 'globals';
3+
import tsParser from '@typescript-eslint/parser';
4+
import js from '@eslint/js';
5+
6+
export default [
7+
js.configs.recommended,
8+
...tsEslint.configs.recommended,
9+
{
10+
languageOptions: {
11+
globals: {
12+
...globals.node,
13+
...globals.commonjs,
14+
...globals.jest
15+
},
16+
17+
parser: tsParser,
18+
ecmaVersion: 2018,
19+
sourceType: 'commonjs'
20+
},
21+
22+
rules: {
23+
camelcase: 'off',
24+
radix: ['error', 'as-needed'],
25+
// quotes: 'off',
26+
// 'require-jsdoc': 'off',
27+
// 'require-atomic-updates': 'off',
28+
29+
'@typescript-eslint/camelcase': 'off',
30+
31+
// remove after totally rewrite to ts
32+
'@typescript-eslint/no-var-requires': 'off',
33+
'@typescript-eslint/explicit-function-return-type': 'off',
34+
'@typescript-eslint/no-explicit-any': 'off',
35+
'@typescript-eslint/ban-ts-comment': 'warn',
36+
'@typescript-eslint/no-unused-expressions': 'off',
37+
'@typescript-eslint/no-unused-vars': [
38+
'error',
39+
{
40+
args: 'all',
41+
argsIgnorePattern: '^_',
42+
caughtErrors: 'all',
43+
caughtErrorsIgnorePattern: '^_',
44+
destructuredArrayIgnorePattern: '^_',
45+
varsIgnorePattern: '^_',
46+
ignoreRestSiblings: true
47+
}
48+
]
49+
}
50+
}
51+
];

0 commit comments

Comments
 (0)