-
-
Notifications
You must be signed in to change notification settings - Fork 23
Closed
Labels
Status: ReleasedThe issue has been releasedThe issue has been releasedType: BugSomething isn't workingSomething isn't working
Description
Describe the bug
I found one case where the no-useless-fragment
rule was incorrectly flagging a fragment that included both a single component accompanied by a
. After running the autofix, it left it in a state that resulted in parsing errors.
Original code
return (
<>
<SomeComponent />
</>
);
"Fixed" code
return (
<SomeComponent />
);
Reproduction
No response
Expected behavior
Should consider html entities when assessing whether a fragment is needed or not.
Platform and versions
Node 22.11
ESLint 9.22.0
Stack trace
Additional context
No response
Metadata
Metadata
Assignees
Labels
Status: ReleasedThe issue has been releasedThe issue has been releasedType: BugSomething isn't workingSomething isn't working