--- a/browser/extensions/formautofill/.eslintrc.js
+++ b/browser/extensions/formautofill/.eslintrc.js
@@ -33,41 +33,32 @@ module.exports = { // eslint-disable-lin
"requireParamDescription": false,
"requireReturn": false,
"requireReturnDescription": false,
}],
// Braces only needed for multi-line arrow function blocks
// "arrow-body-style": ["error", "as-needed"],
- // Always require spacing around a single line block
- "block-spacing": "warn",
-
// Forbid spaces inside the square brackets of array literals.
"array-bracket-spacing": ["error", "never"],
// Forbid spaces inside the curly brackets of object literals.
"object-curly-spacing": ["error", "never"],
// No space padding in parentheses
"space-in-parens": ["error", "never"],
// Enforce one true brace style (opening brace on the same line) and avoid
// start and end braces on the same line.
"brace-style": ["error", "1tbs", {"allowSingleLine": true}],
// Commas at the end of the line not the start
"comma-style": "error",
- // Don't require spaces around computed properties
- "computed-property-spacing": ["warn", "never"],
-
- // Functions are not required to consistently return something or nothing
- "consistent-return": "off",
-
// Require braces around blocks that start a new line
"curly": ["error", "all"],
// Require function* name()
"generator-star-spacing": ["error", {"before": false, "after": true}],
// Two space indent
"indent": ["error", 2, {"SwitchCase": 1}],
@@ -86,51 +77,34 @@ module.exports = { // eslint-disable-lin
// Disallow empty statements. This will report an error for:
// try { something(); } catch (e) {}
// but will not report it for:
// try { something(); } catch (e) { /* Silencing the error because ...*/ }
// which is a valid use case.
"no-empty": "error",
- // No using !! where casting to boolean is already happening
- "no-extra-boolean-cast": "warn",
-
- // No single if block inside an else block
- "no-lonely-if": "warn",
-
- // Disallow use of multiple spaces (sometimes used to align const values,
- // array or object items, etc.). It's hard to maintain and doesn't add that
- // much benefit.
- "no-multi-spaces": "warn",
-
// No spaces between function name and parentheses
"no-spaced-func": "warn",
// No expressions where a statement is expected
"no-unused-expressions": "error",
// No declaring variables that are never used
"no-unused-vars": ["error", {"args": "none", "varsIgnorePattern": "^(Cc|Ci|Cr|Cu|EXPORTED_SYMBOLS)$"}],
// No using variables before defined
"no-use-before-define": "error",
// Always require semicolon at end of statement
"semi": ["error", "always"],
- // Never use spaces before function parentheses
- "space-before-function-paren": ["error", {"anonymous": "never", "named": "never"}],
-
// Require spaces around operators, except for a|"off".
"space-infix-ops": ["error", {"int32Hint": true}],
- // ++ and -- should not need spacing
- "space-unary-ops": ["warn", {"nonwords": false}],
-
// Disallow using variables outside the blocks they are defined (especially
// since only let and const are used, see "no-var").
"block-scoped-var": "error",
// Allow trailing commas for easy list extension. Having them does not
// impair readability, but also not required either.
"comma-dangle": ["error", "always-multiline"],
@@ -226,19 +200,16 @@ module.exports = { // eslint-disable-lin
"no-fallthrough": "error",
// Allow the use of leading or trailing decimal points in numeric literals.
"no-floating-decimal": "off",
// Allow comments inline after code.
"no-inline-comments": "off",
- // Disallow use of labels for anything other then loops and switches.
- "no-labels": ["error", {"allowLoop": true}],
-
// Disallow use of multiline strings (use template strings instead).
"no-multi-str": "warn",
// Disallow multiple empty lines.
"no-multiple-empty-lines": ["warn", {"max": 2}],
// Allow reassignment of function parameters.
"no-param-reassign": "off",
@@ -263,19 +234,16 @@ module.exports = { // eslint-disable-lin
// Don't restrict usage of specified node modules (not a node environment).
"no-restricted-modules": "off",
// Disallow use of assignment in return statement. It is preferable for a
// single line of code to have only one easily predictable effect.
"no-return-assign": "error",
- // Don't warn about declaration of variables already declared in the outer scope.
- "no-shadow": "off",
-
// Allow use of synchronous methods (not a node environment).
"no-sync": "off",
// Allow the use of ternary operators.
"no-ternary": "off",
// Disallow throwing literals (eg. throw "error" instead of
// throw new Error("error")).
@@ -306,32 +274,26 @@ module.exports = { // eslint-disable-lin
"one-var": "off",
// Disallow padding within blocks.
"padded-blocks": ["warn", "never"],
// Don't require quotes around object literal property names.
"quote-props": "off",
- // Double quotes should be used.
- "quotes": ["warn", "double", {"avoidEscape": true, "allowTemplateLiterals": true}],
-
// Require use of the second argument for parseInt().
"radix": "error",
// Enforce spacing after semicolons.
"semi-spacing": ["error", {"before": false, "after": true}],
// Don't require to sort variables within the same declaration block.
// Anyway, one-var is disabled.
"sort-vars": "off",
- // Require a space immediately following the // in a line comment.
- "spaced-comment": ["error", "always"],
-
// Require "use strict" to be defined globally in the script.
"strict": ["error", "global"],
// Allow vars to be declared anywhere in the scope.
"vars-on-top": "off",
// Don't require immediate function invocation to be wrapped in parentheses.
"wrap-iife": "off",