]> git.ipfire.org Git - thirdparty/foundation/foundation-sites.git/commitdiff
chore: update eslint rules to prevent breaking changes and/or prohibit
authorpebutler3 <paul@heysparkbox.com>
Thu, 28 Oct 2021 19:45:27 +0000 (13:45 -0600)
committerpebutler3 <paul@heysparkbox.com>
Thu, 28 Oct 2021 19:45:27 +0000 (13:45 -0600)
readability of code.

- camelCase rule: downgraded to warning level due to possible breaking
  changes caused by changing the regex patterns (alpha_numeric,
month_day_year, day_month_year) may have unforseen consequences
- newCap rule: disabled to prevent breaking changes
- no-extra-parens: disabled to prevent creating scenarios that
  unreadable (i.e. math)

.eslintrc

index f90d6aa1917a2090652a1169369a8599f6549757..0084bda06e51f6055b279dedf4aef90dbc5e5800 100644 (file)
--- a/.eslintrc
+++ b/.eslintrc
@@ -21,7 +21,7 @@
   },
   "rules": {
     "block-scoped-var": 2,
-    "camelcase": 2,
+    "camelcase": 1,
     "comma-style": [2, "last"],
     "curly": [0, "all"],
     "dot-notation": [
@@ -32,7 +32,7 @@
     ],
     "eqeqeq": [2, "allow-null"],
     "guard-for-in": 2,
-    "new-cap": 2,
+    "new-cap": 0,
     "no-bitwise": 2,
     "no-caller": 2,
     "no-cond-assign": [2, "except-parens"],
@@ -40,7 +40,7 @@
     "no-empty": 2,
     "no-eval": 2,
     "no-extend-native": 2,
-    "no-extra-parens": 1,
+    "no-extra-parens": 0,
     "no-irregular-whitespace": 2,
     "no-iterator": 2,
     "no-loop-func": 2,