-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Closed
Labels
Description
Is there an existing issue for this?
- I have searched the existing issues and my issue is uniqueMy issue appears in the command-line and not only in the text editorTo pick up a draggable item, press the space bar. While dragging, use the arrow keys to move the item. Press space again to drop the item in its new position, or press escape to cancel.
Description Overview
This rule:
"react/jsx-props-no-spreading": [
"error",
{
html: "ignore",
custom: "ignore",
explicitSpread: "enforce",
},
],
Results in this crash:
ESLint: 8.57.0
Error: .eslintrc.cjs:
Configuration for rule "react/jsx-props-no-spreading" is invalid:
Value {"html":"ignore","custom":"ignore","explicitSpread":"enforce"} should NOT be valid.
Reproduction:
https://stackblitz.com/edit/vitejs-vite-dyngku?file=eslint.config.js
Run pnpm lint
.
Expected Behavior
Does not crash.
eslint-plugin-react version
^7.35.0
eslint version
^9.8.0
node version
v18.20.3
Metadata
Metadata
Assignees
Labels
Type
Projects
Milestone
Relationships
Development
Select code repository
Activity
[-][Bug]: Cannot ban only explicitSpread[/-][+][Bug]: Cannot ban only explicitSpread for jsx-props-no-spreading[/+]ljharb commentedon Sep 11, 2024
Looks like the schema wasn't changed in #2449, but I can't believe that zero people have tried to use the option in the last 5 years. cc @pawelnvk
ljharb commentedon Sep 11, 2024
ah, maybe this is a new warning in eslint 9, and that's why nobody noticed.
[Fix] `jsx-props-no-spreading`: add `explicitSpread` option to schema
60 remaining items