eslint: disallow inline if-statements

Viewed 36

Is there an eslint rule to disable

if (foo === 'bar') throw new Error('Foo is bar');

and instead suggest/require

if (foo === 'bar') {
  throw new Error('Foo is bar');
}
0 Answers
Related