quick-lint-js

Find bugs in JavaScript programs.

E0090: with statement is missing '(' or ')' around expression

with statements have an expression after the with keyword. It is a syntax error to write an expression without either ( or ):

with (person {
  console.log(`Hi, ${firstName} ${lastName}!`);
}

To fix this error, write ( before the expression or ) after the expression:

with (person) {
  console.log(`Hi, ${firstName} ${lastName}!`);
}

Introduced in quick-lint-js version 0.2.0.

Documentation for other errors