Bug 1215455 - Use eslint --fix to turn on additional rules [r=Standard8]
authorEd Lee <edilee@mozilla.com>
Fri, 16 Oct 2015 01:27:50 -0700
changeset 304179 ffeca1025cd07845ef400d7bcd1b699d075a6cda
parent 304178 214bc95f9d20afb36016a0ff7021695a01f78c1b
child 304180 70d83aad0cc13333ab6ba541f897e6b05e21917a
push id1001
push userraliiev@mozilla.com
push dateMon, 18 Jan 2016 19:06:03 +0000
treeherdermozilla-release@8b89261f3ac4 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersStandard8
bugs1215455
milestone44.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1215455 - Use eslint --fix to turn on additional rules [r=Standard8]
browser/components/loop/.eslintrc
--- a/browser/components/loop/.eslintrc
+++ b/browser/components/loop/.eslintrc
@@ -33,49 +33,53 @@
     // want to audit these rules, and start turning them on and fixing the
     // problems they find, one at a time.
 
     // Eslint built-in rules are documented at <http://eslint.org/docs/rules/>
     "block-spacing": [2, "always"],
     "callback-return": 0,         // TBD
     "camelcase": 0,               // TODO: set to 2
     "comma-spacing": 2,
+    "comma-style": 2,
     "computed-property-spacing": [2, "never"],
     "consistent-return": 0,       // TODO: set to 2
     "curly": [2, "all"],
     "dot-location": [2, "property"],
     "eol-last": 2,
     "eqeqeq": [2, "smart"],
     "jsx-quotes": [2, "prefer-double"],
     "key-spacing": [2, {"beforeColon": false, "afterColon": true }],
     "linebreak-style": [2, "unix"],
     "new-cap": 0,                 // TODO: set to 2
     "new-parens": 2,
     "no-alert": 2,
     "no-array-constructor": 2,
     "no-caller": 2,
-    "no-catch-shadow": 0,         // TODO: set to 2
+    "no-catch-shadow": 2,
     "no-class-assign": 2,
     "no-const-assign": 2,
     "no-console": 0,              // Leave as 0. We use console logging in content code.
     "no-empty": 2,
     "no-empty-label": 2,
     "no-eval": 2,
     "no-extend-native": 2, // XXX
     "no-extra-bind": 0,           // Leave as 0
     "no-extra-parens": 0,         // TODO: (bug?) [2, "functions"],
+    "no-extra-semi": 2,
     "no-implied-eval": 2,
     "no-invalid-this": 0,         // TBD
     "no-iterator": 2,
     "no-label-var": 2,
     "no-labels": 2,
     "no-lone-blocks": 2,
     "no-loop-func": 2,
+    "no-mixed-spaces-and-tabs": 2,
     "no-multi-spaces": 0,         // TBD.
     "no-multi-str": 2,
+    "no-multiple-empty-lines": 2,
     "no-native-reassign": 2,
     "no-new": 2,
     "no-new-func": 2,
     "no-new-object": 2,
     "no-new-wrappers": 2,
     "no-octal-escape": 2,
     "no-process-exit": 2,
     "no-proto": 2,
@@ -94,32 +98,31 @@
     "no-unused-vars": 0,          // TODO: Set to 2
     "no-use-before-define": 0,    // TODO: Set to 2
     "no-useless-call": 2,
     "no-with": 2,
     "object-curly-spacing": 0,    // [2, "always"],
     "quotes": [2, "double", "avoid-escape"],
     "semi": 2,
     "semi-spacing": [2, {"before": false, "after": true}],
+    "space-before-keywords": 2,
     "space-infix-ops": 2,
     "space-return-throw-case": 2,
     "space-unary-ops": [2, {"words": true, "nonwords": false}],
     "spaced-comment": [2, "always"],
     "strict": [2, "function"],
     "yoda": [2, "never"],
     // eslint-plugin-react rules. These are documented at
     // <https://github.com/yannickcr/eslint-plugin-react#list-of-supported-rules>
     "react/jsx-no-undef": 2,
     "react/jsx-sort-props": 2,
     "react/jsx-sort-prop-types": 2,
     "react/jsx-uses-vars": 2,
     "react/jsx-no-duplicate-props": 2,
-    // Need to fix the couple of instances which don't
-    // currently pass this rule.
-    "react/no-did-mount-set-state": 0,
+    "react/no-did-mount-set-state": 2,
     "react/no-did-update-set-state": 2,
     "react/no-unknown-property": 2,
     "react/prop-types": 2,
     "react/self-closing-comp": 2,
     "react/wrap-multilines": 2,
     // We would probably want to go with a variant of never.
     "react/jsx-curly-spacing": 0,
     // Not worth it: React is defined globally