Skip to content

Commit f3f3caf

Browse files
committed
refactor: Upgrade to ESLint v10 and disable noisy new rules
Update companion packages alongside eslint v10: - @eslint/js: ^9.8.0 → ^10.0.1 - eslint-plugin-ava: ^15.1.0 → ^17.0.1 - eslint-plugin-jsdoc: ^62.5.4 → ^63.0.2 Adapt eslint.common.config.js for ESLint v10 behavior: - Scope js.configs.recommended and eslint-config-google to JS files only, since ava v17 now introduces a json/json language config for package.json files that would otherwise cause JS-only rules to error on JSON - Change ava.configs["flat/recommended"] to ...ava.configs.recommended (the config key was renamed in ava v17) - Disable rules that are new or stricter in ESLint v10 / ava v17 and produce too much noise against the existing codebase Also fix one genuine ava/test-title violation (trailing whitespace in a test title) in packages/cli/test/lib/cli/commands/build.js.
1 parent 614585b commit f3f3caf

2 files changed

Lines changed: 13 additions & 1 deletion

File tree

eslint.common.config.js

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,18 @@ export default [{
101101

102102
"jsdoc/valid-types": 0,
103103
"ava/assertion-arguments": 0,
104+
// Rules introduced or made stricter in ESLint v10 / eslint-plugin-ava v17
105+
// that produce too much noise for the existing codebase:
106+
"preserve-caught-error": 0,
107+
"no-useless-assignment": 0,
108+
"no-unassigned-vars": 0,
109+
"ava/no-useless-t-pass": 0,
110+
"ava/no-conditional-assertion": 0,
111+
"ava/no-nested-assertions": 0,
112+
"ava/require-assertion": 0,
113+
"ava/prefer-t-throws": 0,
114+
"ava/no-async-fn-without-await": 0,
115+
"ava/use-true-false": 0,
104116
},
105117
}
106118
];

packages/cli/test/lib/cli/commands/build.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ test.afterEach.always((t) => {
9393
esmock.purge(t.context.build);
9494
});
9595

96-
test.serial("ui5 build (default) ", async (t) => {
96+
test.serial("ui5 build (default)", async (t) => {
9797
const {build, argv, builder, expectedBuilderArgs} = t.context;
9898

9999
await build.handler(argv);

0 commit comments

Comments
 (0)