From ee2cb41ec4ccc1bbf434c06a89643020aa2fb3b8 Mon Sep 17 00:00:00 2001 From: Jordan Harband Date: Mon, 20 Jun 2016 15:52:05 -0700 Subject: [PATCH] [eslint config] [base] [breaking] enable `no-mixed-operators` rule. Specifically, this is to require parens to avoid cognitive overhead about precedence. --- packages/eslint-config-airbnb-base/rules/style.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/packages/eslint-config-airbnb-base/rules/style.js b/packages/eslint-config-airbnb-base/rules/style.js index dbb305ed..8953957e 100644 --- a/packages/eslint-config-airbnb-base/rules/style.js +++ b/packages/eslint-config-airbnb-base/rules/style.js @@ -138,8 +138,7 @@ module.exports = { // disallow un-paren'd mixes of different operators // http://eslint.org/docs/rules/no-mixed-operators - // TODO: enable - 'no-mixed-operators': [0, { + 'no-mixed-operators': [2, { groups: [ ['+', '-', '*', '/', '%', '**'], ['&', '|', '^', '~', '<<', '>>', '>>>'],