Skip to content

Commit 0f37d1c

Browse files
committed
eslint improvements
1 parent 58d0560 commit 0f37d1c

File tree

3 files changed

+440
-876
lines changed

3 files changed

+440
-876
lines changed

eslint.config.ts

Lines changed: 14 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,7 @@ import js from '@eslint/js';
22
import globals from 'globals';
33
import tseslint from 'typescript-eslint';
44
import { defineConfig } from 'eslint/config';
5-
import stylisticJs from '@stylistic/eslint-plugin-js';
6-
import stylisticTs from '@stylistic/eslint-plugin-ts';
5+
import stylistic from '@stylistic/eslint-plugin';
76

87
export default defineConfig([
98
{ files: ['**/*.{js,mjs,cjs,ts}'], plugins: { js }, extends: ['js/recommended'] },
@@ -17,46 +16,46 @@ export default defineConfig([
1716
},
1817
},
1918
plugins: {
20-
'@stylistic/js': stylisticJs,
21-
'@stylistic/ts': stylisticTs,
19+
'@stylistic': stylistic,
2220
},
2321
rules: {
24-
'@stylistic/js/no-trailing-spaces': 'error',
25-
'@stylistic/ts/indent': ['error', 2],
26-
'@stylistic/ts/lines-between-class-members': [
22+
'@stylistic/comma-dangle': ['error', 'always-multiline'],
23+
'@stylistic/indent': ['error', 2],
24+
'@stylistic/lines-between-class-members': [
2725
'error',
2826
'always',
2927
{
3028
exceptAfterOverload: true,
3129
exceptAfterSingleLine: true,
3230
},
3331
],
34-
'@stylistic/ts/padding-line-between-statements': [
32+
'@stylistic/no-trailing-spaces': 'error',
33+
'@stylistic/object-curly-spacing': ['error', 'always'],
34+
'@stylistic/padding-line-between-statements': [
3535
'error',
3636
// Return statements
3737
{ blankLine: 'always', prev: '*', next: 'return' },
3838
// Import statements
3939
{ blankLine: 'always', prev: 'import', next: '*' },
4040
{ blankLine: 'any', prev: 'import', next: 'import' },
4141
],
42-
'@stylistic/ts/quotes': ['error', 'single'],
43-
'@stylistic/ts/semi': ['error', 'always'],
42+
'@stylistic/quotes': ['error', 'single'],
43+
'@stylistic/semi': ['error', 'always'],
4444
'@typescript-eslint/consistent-type-imports': [
4545
'error',
4646
{
4747
prefer: 'type-imports',
4848
fixStyle: 'separate-type-imports',
4949
},
50-
],
51-
'@typescript-eslint/no-empty-object-type': 'off',
50+
], // todo fix it
51+
'@typescript-eslint/no-empty-object-type': 'off', // todo fix it
5252
'@typescript-eslint/no-redundant-type-constituents': 'off', // todo fix it
5353
'@typescript-eslint/no-unnecessary-condition': 'error', // todo fix it
5454
'@typescript-eslint/no-unsafe-argument': 'off', // todo fix it
55-
'@typescript-eslint/no-unsafe-assignment': 'off', // todo fix it
56-
'@typescript-eslint/no-unsafe-call': 'off', // todo fix it
55+
'@typescript-eslint/no-unsafe-assignment': 'off',
56+
'@typescript-eslint/no-unsafe-call': 'off',
5757
'@typescript-eslint/no-unsafe-member-access': 'off',
5858
'@typescript-eslint/prefer-optional-chain': 'error',
59-
'@stylistic/ts/object-curly-spacing': ["error", "always"]
6059
},
6160
},
6261
]);

package.json

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -118,32 +118,31 @@
118118
"dependencies": {
119119
"axios": "^1.9.0",
120120
"mime": "^4.0.7",
121-
"zod": "^3.24.4"
121+
"zod": "^3.25.56"
122122
},
123123
"devDependencies": {
124-
"@eslint/js": "^9.26.0",
124+
"@eslint/js": "^9.28.0",
125125
"@rollup/plugin-alias": "^5.1.1",
126126
"@rollup/plugin-commonjs": "^28.0.3",
127127
"@rollup/plugin-node-resolve": "^16.0.1",
128128
"@rollup/plugin-typescript": "^12.1.2",
129-
"@stylistic/eslint-plugin-js": "^4.2.0",
130-
"@stylistic/eslint-plugin-ts": "^4.2.0",
131-
"@types/node": "^20.17.47",
129+
"@stylistic/eslint-plugin": "^4.4.1",
130+
"@types/node": "^20.19.0",
132131
"@types/sinon": "^17.0.4",
133132
"dotenv": "^16.5.0",
134-
"eslint": "^9.26.0",
135-
"globals": "^16.1.0",
133+
"eslint": "^9.28.0",
134+
"globals": "^16.2.0",
136135
"jiti": "^2.4.2",
137136
"prettier": "^3.5.3",
138137
"prettier-plugin-jsdoc": "^1.3.2",
139-
"rollup": "^4.40.2",
140-
"rollup-plugin-esnext-to-nodenext": "^1.0.0",
138+
"rollup": "^4.42.0",
139+
"rollup-plugin-esnext-to-nodenext": "^1.0.1",
141140
"rollup-plugin-node-externals": "^8.0.0",
142141
"sinon": "^20.0.0",
143142
"tslib": "^2.8.1",
144-
"typedoc": "^0.28.4",
143+
"typedoc": "^0.28.5",
145144
"typescript": "^5.8.3",
146-
"typescript-eslint": "^8.32.1",
147-
"vitest": "^3.1.3"
145+
"typescript-eslint": "^8.34.0",
146+
"vitest": "^3.2.3"
148147
}
149148
}

0 commit comments

Comments
 (0)