Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to eslint 9 #40555

Merged
merged 9 commits into from
Dec 11, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .pnpmfile.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,11 @@ function fixDeps( pkg ) {
pkg.peerDependencies[ dep ] = ver.replace( /^\^?/, '>=' );
}
}

// Doesn't really need these at all with eslint 9 and our config.
pkg.peerDependenciesMeta ??= {};
pkg.peerDependenciesMeta[ '@typescript-eslint/eslint-plugin' ] = { optional: true };
pkg.peerDependenciesMeta[ '@typescript-eslint/parser' ] = { optional: true };
}

// Unnecessarily explicit deps. I don't think we really even need @wordpress/babel-preset-default at all.
Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@
"cli-setup": "pnpm install && jetpack cli link",
"cli-unlink": "jetpack cli unlink",
"lint": "pnpm run lint-file .",
"lint-changed": "eslint-changed --ext .js,.jsx,.cjs,.mjs,.ts,.tsx,.svelte --git",
"lint-file": "eslint --ext .js,.jsx,.cjs,.mjs,.ts,.tsx,.svelte",
"lint-changed": "eslint-changed --ext .js,.jsx,.cjs,.mjs,.ts,.tsx,.svelte --eslint-options flags='[\"unstable_config_lookup_from_file\"]' --git",
"lint-file": "eslint --flag unstable_config_lookup_from_file",
tbradsha marked this conversation as resolved.
Show resolved Hide resolved
"lint-required": "ESLINT_IGNORE_REQUIRED=1 pnpm run lint --max-warnings=0",
"php:autofix": "composer phpcs:fix",
"php:compatibility": "composer phpcs:compatibility",
Expand All @@ -28,7 +28,7 @@
"version-packages": "bash ./tools/version-packages.sh"
},
"devDependencies": {
"eslint": "8.57.1",
"eslint": "9.16.0",
"husky": "8.0.3",
"jetpack-cli": "workspace:*",
"jetpack-js-tools": "workspace:*"
Expand Down
Loading