Fix third example in Enclosed operators section

This commit is contained in:
Ilici
2017-12-14 23:14:27 +01:00
parent 4817a6b75c
commit 255b0f369a

View File

@@ -1957,6 +1957,7 @@ Other Style Guides
const bar = a ** b - 5 % d;
// bad
// one may be confused into thinking (a || b) && c
if (a || b && c) {
return d;
}
@@ -1968,7 +1969,7 @@ Other Style Guides
const bar = (a ** b) - (5 % d);
// good
if ((a || b) && c) {
if (a || (b && c)) {
return d;
}