You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
useExplicitLengthCheck ruins multi-line conditions that have single-line comments #7984
changed the title [-]useExplicitLengthCheck ruins multiline conditions with single-line comments[/-][+]useExplicitLengthCheck ruins multi-line conditions that have single-line comments[/+]on Nov 4, 2025
Actually the same issue happens with the useSimplifiedLogicExpression rule:
if (
- !showRequestSizeWarning ||- !query.metrics // context was too large to count tokens+ !(showRequestSizeWarning &&query.metrics // context was too large to count tokens) // context was too large to count tokens
) {/* ... */}
Activity
[-]useExplicitLengthCheck ruins multiline conditions with single-line comments[/-][+]useExplicitLengthCheck ruins multi-line conditions that have single-line comments[/+]GeneZharov commentedon Nov 4, 2025
Actually the same issue happens with the useSimplifiedLogicExpression rule:
dyc3 commentedon Nov 4, 2025
I'm not seeing this behavior for either of those rules in the playground.
GeneZharov commentedon Nov 4, 2025
See the suggested unsafe fix in the console tab.
And Biome actually applies this change when I run the following command:
github-actions commentedon Nov 4, 2025
Hello @GeneZharov, please provide a minimal reproduction. You can use one of the following options:
npm create @biomejs/biome-reproductionIssues marked with
S-Needs reprowill be closed if they have no activity within 3 days.Update dependency @biomejs/biome to v2.5.14 (#24)
Update dependency @biomejs/biome to v2.5.14 (#45)