website/src/pages/lint/rules/noCommaOperator.md
This rule is recommended by Rome.
Disallow comma operator.
The comma operator includes multiple expressions where only one is expected. It evaluates every operand from left to right and returns the value of the last operand. It frequently obscures side effects, and its use is often an accident.
The use of the comma operator in the initialization and update parts of a for is still allowed.
Source: https://eslint.org/docs/latest/rules/no-sequences
const foo = (doSomething(), 0);
for (; doSomething(), !!test; ) {}
// Use a semicolon instead.
let a, b;
a = 1, b = 2;
for(a = 0, b = 0; (a + b) < 10; a++, b += 2) {}