Skip to content

Releases: rEl1cx/eslint-react

v1.23.2 (2025-01-07)

07 Jan 03:30
6f563be
Compare
Choose a tag to compare

What's Changed

No notable changes in this release.

Full Changelog: v1.23.1...v1.23.2

v1.23.1 (2025-01-03)

02 Jan 22:12
51e9171
Compare
Choose a tag to compare

What's Changed

🐞 Fixes

  • fix(plugins/x): fixed false positives in no-unstable-context-value and no-unstable-default-props by @rEl1cx in #896

Full Changelog: v1.23.0...v1.23.1

v1.23.0

31 Dec 10:41
8182809
Compare
Choose a tag to compare

What's Changed

🪄 Improvements

  • refactor: JSX fragments related rules no longer rely on jsxPragma and jsxPragmaFrag settings to perform their checks by @rEl1cx in #893
  • refactor: improve applicability of the no-useless-fragment and prefer-shorthand-fragment rules
  • refactor: deprecate settings["react-x"].jsxPragma and settings["react-x"].jsxPragmaFrag as they are no longer needed by any rules
  • refactor: replace short-unique-id w/ uid by @SukkaW in #894

🐞 Fixes

  • fix(plugins/hooks-extra): fix call and new expression related false positives in no-unnecessary-use-memo and no-unnecessary-use-callback by @rEl1cx in #895

Full Changelog: v1.22.2...v1.23.0

v1.22.2

30 Dec 12:03
ca79f16
Compare
Choose a tag to compare

What's Changed

🪄 Improvements

  • perf: re-implement no-duplicate-key rule to improve its performance @rEl1cx in #891 and 33ab3cc
  • refactor: prevent potential interference from TypeScript's as, satisfies, and non-null assertion operator in various rules

v1.22.1

23 Dec 21:28
f63bcc8
Compare
Choose a tag to compare

What's Changed

🪄 Improvements

  • docs: add getting started guides for JavaScript, TypeScript, and JavaScript with Babel
  • docs: improve code samples in rules docs
  • docs: improve eslint.config.js examples in README.md, docs and the examples folder
  • docs: improve the error message and description of various rules
  • refactor(website): better website layout and navigation experience

📝 Changes in examples

The eslint.config.js in the examples now uses tsconfig's includes and excludes as the SSoT glob patterns for ESLint's files and ignores fields. This approach can fundamentally avoid the errors[1, 2, 3] caused by mismatched config scopes between tsconfig.json and eslint.config.js when using type-checked rules.

Full Changelog: v1.22.0...v1.22.1

v1.22.0

21 Dec 23:30
c55945e
Compare
Choose a tag to compare

What's Changed

🪄 Improvements

  • refactor(plugins/x): rename jsx-use-vars to use-jsx-vars
  • refactor(plugins/x): rename jsx-no-duplicate-props to no-duplicate-jsx-props
  • refactor(plugins/dom): rename no-children-in-void-dom-elements to no-void-elements-with-children

📝 Changes you should be aware of

The following rules have been renamed:

  • jsx-uses-vars to use-jsx-vars
  • jsx-no-duplicate-props to no-duplicate-jsx-props
  • dom/no-children-in-void-dom-elements to dom/no-void-elements-with-children

The new rule names are aligned with the same rules in the biomejs/rules-sources/#eslint-plugin-react (if any) to enhance consistency. The old rule names will still be available until the next major update to avoid breaking changes.

Full Changelog: v1.21.0...v1.22.0

v1.21.0

20 Dec 02:29
4cccae1
Compare
Choose a tag to compare

What's Changed

✨ New

  • feat(plugins/hooks-extra): add no-useless-custom-hooks rule by @rEl1cx

🪄 Improvements

  • refactor(plugins/hooks-extra): deprecate rule no-redundant-custom-hook in favor of no-useless-custom-hooks (the previous rule will still be available until the next major update to avoid breaking changes)
  • docs: document active rules, closes #830 by @rEl1cx in #882
  • docs: add setup instructions and example to pure JS project, closes #844 by @rEl1cx in #885

📝 Changes in Rule implementation

no-useless-custom-hooks now detects Hook calls within comments and the following code no longer triggers a warning:

// ✅ Good: A Hook that will likely use some other Hooks later
function useAuth() {
  // TODO: Replace with this line when authentication is implemented:
  // return useContext(Auth);
  return TEST_USER;
}

Full Changelog: v1.20.1...v1.21.0

v1.20.1

18 Dec 03:55
2d47f1c
Compare
Choose a tag to compare

What's Changed

🪄 Improvements

  • refactor(shared): replace local-pkg package with node built-in API by @rEl1cx in #881

Full Changelog: v1.20.0...v1.20.1

v1.20.0

16 Dec 12:36
138b46c
Compare
Choose a tag to compare

What's Changed

✨ New

  • feat(plugins/x): add codemod-autofix to no-component-will-* by @rEl1cx in #879

🪄 Improvements

  • refactor: use default settings when no settings are provided in settings["react-x"] by @rEl1cx in 40ca3bd
  • docs: update no-context-provider.mdx by @danielrentz in #877
  • docs: add 'Min. React' column to rules overview page by @rEl1cx in #880
  • docs: add features section to rules overview page by @rEl1cx

New Contributors

Full Changelog: v1.19.0...v1.20.0

v1.19.0

09 Dec 21:58
0093526
Compare
Choose a tag to compare

What's Changed

✨ New

  • feat(plugins/x): add no-context-provider rule by @rEl1cx
  • feat(plugins/x): add autofix for no-forward-ref rule by @rEl1cx in #874
  • feat(plugins/eslint-plugin): add no-forward-ref and no-context-provider to recommended presets by @rEl1cx

🪄 Improvements

  • refactor(plugins/eslint-plugin): remove prefer-read-only-props from recommended-type-checked preset by @rEl1cx in #872
  • refactor(plugins/eslint-plugin): hide avoid-shorthand-boolean and avoid-shorthand-fragment from presets and docs by @rEl1cx in #876
  • Update @typescript-eslint's packages to ^8.18.0

Full Changelog: v1.18.0...v1.19.0