
Highlights
--ext CLI Option
This version of ESLint reintroduces the command line option --ext to allow linting files with a particular extension.
The --ext option has always been available in the legacy “eslintc” configuration system, but it was eliminated in the new configuration system because its functionality can be easily achieved through files patterns.
For example, specifying files: ["**/*.ts"] in a configuration object will lint all files that have the .ts extension.
files patterns are useful to lint files with extensions other than .js, .mjs or .cjs, but they require a configuration file. In order to lint files with arbitrary extensions without a configuration file, the --ext option can now be used in the command line like this:
npx eslint --no-config-lookup --rule '{"no-unused-vars": "error"}' --ext '.jsx'
See the CLI documentation for further information.
New Metadata for Deprecated Rules
ESLint v9.21.0 extends the format of rule metadata to better annotate deprecated rules, providing more detailed information. This includes the specific version of a plugin in which a rule was deprecated, as well as links to alternative rules and plugins. Learn more.
Features
418717ffeat: introduce new deprecated types for rules (#19238) (fnx)5c5b802feat: Add--extCLI option (#19405) (Milos Djermanovic)
Bug Fixes
db5340dfix: update missing plugin message template (#19445) (Milos Djermanovic)d8ffdd4fix: do not exit process on rule crash (#19436) (Francesco Trotta)
Documentation
c5561eadocs: Update README (GitHub Actions Bot)80b0485docs: replacevarwithletandconstin rule example (#19434) (Tanuj Kanti)f67d5e8docs: Update README (GitHub Actions Bot)75afc61docs: Update README (GitHub Actions Bot)0636cabdocs: Update Eleventy from v2 to v3 (#19415) (Amaresh S M)dd7d930docs: Update README (GitHub Actions Bot)
Chores
a8c9a9fchore: update@eslint/eslintrcand@eslint/js(#19453) (Francesco Trotta)265e0cfchore: package.json update for @eslint/js release (Jenkins)3401b85test: add test forRule.ReportDescriptortype (#19449) (Francesco Trotta)e497aa7chore: update rewrite dependencies (#19448) (Francesco Trotta)dab5478chore: better error message for missing plugin in config (#19402) (Tanuj Kanti)ebfe2ebchore: set js language for bug report issue config block (#19439) (Josh Goldberg ✨)5fd211dtest: processors can return subpaths (#19425) (Milos Djermanovic)
