💅 noUselessFragments
autofix causes syntax error on component props
#1335
Labels
A-Linter
Area: linter
L-JavaScript
Language: JavaScript and super languages
S-Bug-confirmed
Status: report has been confirmed as a valid bug
S-Help-wanted
Status: you're familiar with the code base and want to help the project
Environment information
Rule name
noUselessFragments
Playground link
https://biomejs.dev/playground/?code=aQBtAHAAbwByAHQAIAB7ACAAUwB1AHMAcABlAG4AcwBlACAAfQAgAGYAcgBvAG0AIAAiAHIAZQBhAGMAdAAiADsACgBpAG0AcABvAHIAdAAgAHsAIABDAG8AbQBwACAAfQAgAGYAcgBvAG0AIAAiAC4ALwBjAG8AbQBwAG8AbgBlAG4AdABzAC8AQwBvAG0AcAAiADsACgAKAGUAeABwAG8AcgB0ACAAZgB1AG4AYwB0AGkAbwBuACAAQwBvAG0AcABvAG4AZQBuAHQAKAApACAAewAKACAAIAByAGUAdAB1AHIAbgAgACgACgAgACAAIAAgADwAZABpAHYAPgAKACAAIAAgACAAIAAgADwAUwB1AHMAcABlAG4AcwBlACAAZgBhAGwAbABiAGEAYwBrAD0AewA8AD4APAAvAD4AfQA%2BAAoAIAAgACAAIAAgACAAIAAgADwAaAAxAD4ASABpADwALwBoADEAPgAKACAAIAAgACAAIAAgADwALwBTAHUAcwBwAGUAbgBzAGUAPgAKAAoAIAAgACAAIAAgACAAPABDAG8AbQBwACAAcAByAG8AcAA9AHsAPAA%2BADwALwA%2BAH0AIAAvAD4ACgAgACAAIAAgADwALwBkAGkAdgA%2BAAoAIAAgACkAOwAKAH0ACgA%3D
Expected result
I do not believe this to be a "useless fragment", so I expected it to not trigger the
noUselessFragments
rule.However, even if this is deemed to be a useless fragment, the autofix is not correct, as it causes a syntax error.
e.g.
<Suspense fallback={<></>}>
-><Suspense fallback=>
Code of Conduct
The text was updated successfully, but these errors were encountered: