Skip to content

Commit 352da92

Browse files
chore: bump typescript-eslint from 7.18.0 to 8.0.0 (#3493)
Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Jason Dent <[email protected]>
1 parent b0633ff commit 352da92

File tree

26 files changed

+115
-110
lines changed

26 files changed

+115
-110
lines changed

docs/_scripts/extract-config.mjs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -377,7 +377,7 @@ function beautifyJSON(json, width) {
377377
continue;
378378
}
379379
if (line.length + text.length > width) {
380-
line && lines.push(line);
380+
if (line) lines.push(line);
381381
line = '';
382382
}
383383
line += text;
@@ -401,7 +401,7 @@ function beautifyJSON(json, width) {
401401
addToLine('\n', '}');
402402
}
403403

404-
line && lines.push(line);
404+
if (line) lines.push(line);
405405

406406
// console.error('%o', lines);
407407

@@ -432,7 +432,7 @@ function beautifyType(dataType, width) {
432432
continue;
433433
}
434434
if (line.length + text.length > width) {
435-
line && lines.push(line);
435+
if (line) lines.push(line);
436436
line = '';
437437
}
438438
line += text;
@@ -443,7 +443,7 @@ function beautifyType(dataType, width) {
443443
const fixed = items.map((item, index) => item + (index === items.length - 1 ? '' : ' |'));
444444

445445
addToLine(...fixed);
446-
line && lines.push(line);
446+
if (line) lines.push(line);
447447

448448
// console.error('%o', lines);
449449

eslint.config.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,4 +104,10 @@ export default tsEslint.config(
104104
'no-undef': 'off',
105105
},
106106
},
107+
{
108+
files: ['**/*.json'],
109+
rules: {
110+
'@typescript-eslint/no-unused-expressions': 'off',
111+
},
112+
},
107113
);

package-lock.json

Lines changed: 62 additions & 68 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4033,7 +4033,7 @@
40334033
"rollup-plugin-dts": "^6.1.1",
40344034
"shx": "^0.3.4",
40354035
"typescript": "^5.5.4",
4036-
"typescript-eslint": "^7.18.0",
4036+
"typescript-eslint": "^8.0.0",
40374037
"vite": "^5.3.5",
40384038
"vitest": "^2.0.4"
40394039
},

packages/__utils/src/EventEmitter/operators/debounce.mts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ export function debounce<T>(waitMs: number): EventOperator<T, T> {
2828
function handleTimer() {
2929
const value = pendingValue;
3030
clear();
31-
value !== symbolNotSet && fire(value);
31+
if (value !== symbolNotSet) fire(value);
3232
}
3333
},
3434
{

packages/__utils/src/errors.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
function getTypeOf(t: unknown) {
1+
function _getTypeOf(t: unknown) {
22
return typeof t;
33
}
4-
type TypeOfTypes = ReturnType<typeof getTypeOf>;
4+
type TypeOfTypes = ReturnType<typeof _getTypeOf>;
55

66
type AllowedTypes = Partial<Record<TypeOfTypes, true>>;
77

packages/_integrationTests/src/extension.test.mts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
/* eslint-disable @typescript-eslint/no-unused-expressions */
12
import { createRequire } from 'node:module';
23

34
import { expect } from 'chai';

packages/_server/src/codeActions.mts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ class CodeActionHandler {
177177
if (isSpellingIssue && word && spellCheckerDiags.length) {
178178
const wConfig = await pWorkspaceConfig;
179179
const targets = await calculateConfigTargets(docSetting, wConfig);
180-
debugTargets && logTargets(targets);
180+
if (debugTargets) logTargets(targets);
181181

182182
if (!docSetting.hideAddToDictionaryCodeActions) {
183183
actions.push(...generateTargetActions(textDocument, spellCheckerDiags, word, targets));
@@ -216,7 +216,7 @@ class CodeActionHandler {
216216
if (word && eslintSpellCheckerDiags.length) {
217217
const wConfig = await pWorkspaceConfig;
218218
const targets = await calculateConfigTargets(docSetting, wConfig);
219-
debugTargets && logTargets(targets);
219+
if (debugTargets) logTargets(targets);
220220

221221
if (!docSetting.hideAddToDictionaryCodeActions) {
222222
actions.push(...generateTargetActions(textDocument, eslintSpellCheckerDiags, word, targets));

packages/_server/src/config/cspellConfig/cspellConfig.mts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import type { FileTypesAndSchemeSettings } from './FileTypesAndSchemeSettings.mj
1010
import type { PrefixWithCspell } from './Generics.mjs';
1111
import type { SpellCheckerBehaviorSettings, SpellCheckerSettings } from './SpellCheckerSettings.mjs';
1212

13-
interface InternalSettings {}
13+
type InternalSettings = object;
1414

1515
export interface CSpellUserSettings extends SpellCheckerSettings, CSpellSettingsPackageProperties, InternalSettings {}
1616

packages/_server/src/test/mock-node-watch.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import { vi } from 'vitest';
55

66
// declare function watch(pathName: PathName): Watcher;
77
// declare function watch(pathName: PathName, options: Options): Watcher;
8+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
89
declare function watch(pathName: PathName, callback: Callback): Watcher;
910
// declare function watch(pathName: PathName, options: Options, callback: Callback): Watcher;
1011

packages/client/src/Subscribables/operators/debounce.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ export function debounce<T>(waitMs: number): OperatorFn<T, T> {
2323
const value = pendingValue;
2424
pendingValue = symbolNotSet;
2525
timer = undefined;
26-
value !== symbolNotSet && notify(value);
26+
if (value !== symbolNotSet) notify(value);
2727
}
2828
});
2929
subscribable.onEvent('onStop', () => clearTimeout(timer));

0 commit comments

Comments
 (0)