diff --git a/CHANGELOG.md b/CHANGELOG.md index 7aa2c37164..6d08f1f0a2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,6 +13,7 @@ This change log adheres to standards from [Keep a CHANGELOG](https://keepachange ### Fixed * [`function-component-definition`], [`boolean-prop-naming`], [`jsx-first-prop-new-line`], [`jsx-props-no-multi-spaces`], `propTypes`: use type args ([#3629][] @HenryBrown0) * JSX pragma: fail gracefully ([#3632][] @ljharb) +* [`jsx-props-no-spreading`]: add `explicitSpread` option to schema ([#3799][] @ljharb) ### Changed * [Tests] add @typescript-eslint/parser v6 ([#3629][] @HenryBrown0) @@ -21,6 +22,7 @@ This change log adheres to standards from [Keep a CHANGELOG](https://keepachange * [types] add jsdoc type annotations ([#3731][] @y-hsgw) * [Tests] `button-has-type`: add test case with spread ([#3731][] @y-hsgw) +[#3799]: https://github.com/jsx-eslint/eslint-plugin-react/issues/3799 [#3632]: https://github.com/jsx-eslint/eslint-plugin-react/issues/3632 [#3812]: https://github.com/jsx-eslint/eslint-plugin-react/pull/3812 diff --git a/lib/rules/jsx-props-no-spreading.js b/lib/rules/jsx-props-no-spreading.js index a608011cd1..1aa8ab4ace 100644 --- a/lib/rules/jsx-props-no-spreading.js +++ b/lib/rules/jsx-props-no-spreading.js @@ -60,6 +60,9 @@ module.exports = { custom: { enum: [OPTIONS.enforce, OPTIONS.ignore], }, + explicitSpread: { + enum: [OPTIONS.enforce, OPTIONS.ignore], + }, exceptions: { type: 'array', items: {