quick-lint-js

Find bugs in JavaScript programs.

E0210: unopened block comment

Block comments start with /* and end with */. It is a syntax error for a block comment to end but not start:

//
// this code is really complicated.
// some might say too complicated.
*/
function yes() {
  return true;
}

/*
console.log("[debug] state:");
debugPrint(state, /*depth=*/3);
*/

let heightInFeet = heightInCM */ 3.28;

To fix this error, remove the */:

//
// this code is really complicated.
// some might say too complicated.
function yes() {
  return true;
}

Alternatively, use // or if (false) to avoid nesting block comments:

if (false) {
  console.log("[debug] state:");
  debugPrint(state, /*depth=*/3);
}

Alternatively, write an expression between * and /:

let heightInFeet = heightInCM * 100 / 3.28;

Documentation for other errors