From b3afacaabb9990c14b4bafee623edb0096ca4f2e Mon Sep 17 00:00:00 2001 From: Rich Trott Date: Wed, 9 Nov 2022 19:54:14 -0800 Subject: [PATCH] tools: simplify .eslintrc.js Remove explicit setting of configuration options in rules when those options are the defaults. --- .eslintrc.js | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.eslintrc.js b/.eslintrc.js index 2a10875dd34ebd..435df9b74a7cb5 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -117,8 +117,8 @@ module.exports = { // https://eslint.org/docs/rules/ 'accessor-pairs': 'error', 'array-callback-return': 'error', - 'arrow-parens': ['error', 'always'], - 'arrow-spacing': ['error', { before: true, after: true }], + 'arrow-parens': 'error', + 'arrow-spacing': 'error', 'block-scoped-var': 'error', 'block-spacing': 'error', 'brace-style': ['error', '1tbs', { allowSingleLine: true }], @@ -162,9 +162,9 @@ module.exports = { ObjectExpression: 'first', SwitchCase: 1, }], - 'key-spacing': ['error', { mode: 'strict' }], + 'key-spacing': 'error', 'keyword-spacing': 'error', - 'linebreak-style': ['error', 'unix'], + 'linebreak-style': 'error', 'max-len': ['error', { code: 120, ignorePattern: '^// Flags:', @@ -178,7 +178,7 @@ module.exports = { 'no-constant-condition': ['error', { checkLoops: false }], 'no-constructor-return': 'error', 'no-duplicate-imports': 'error', - 'no-else-return': ['error', { allowElseIf: true }], + 'no-else-return': 'error', 'no-extra-parens': ['error', 'functions'], 'no-lonely-if': 'error', 'no-mixed-requires': 'error', @@ -285,7 +285,7 @@ module.exports = { named: 'never', asyncArrow: 'always', }], - 'space-in-parens': ['error', 'never'], + 'space-in-parens': 'error', 'space-infix-ops': 'error', 'space-unary-ops': 'error', 'spaced-comment': ['error', 'always', {