Bug 1326479 - Enable more options for the 'indent' rule. r?jryans
MozReview-Commit-ID: EuxayyLNHNt
--- a/browser/components/migration/.eslintrc.js
+++ b/browser/components/migration/.eslintrc.js
@@ -19,17 +19,17 @@ module.exports = { // eslint-disable-lin
"comma-dangle": "off",
"comma-spacing": ["warn", {"before": false, "after": true}],
"comma-style": ["warn", "last"],
// "complexity": "warn",
"consistent-return": "error",
//"curly": "error",
"dot-notation": "error",
"eol-last": "error",
- "indent": ["warn", 2, {"SwitchCase": 1}],
+ "indent": ["warn", 2, {"SwitchCase": 1, "ArrayExpression": "first", "ObjectExpression": "first"}],
// "key-spacing": ["warn", {"beforeColon": false, "afterColon": true}],
"keyword-spacing": "warn",
"max-nested-callbacks": ["error", 3],
"new-parens": "error",
"no-array-constructor": "error",
"no-cond-assign": "error",
"no-control-regex": "error",
"no-debugger": "error",
--- a/devtools/.eslintrc.js
+++ b/devtools/.eslintrc.js
@@ -137,17 +137,17 @@ module.exports = {
"generator-star": "off",
// Enforce the spacing around the * in generator functions.
"generator-star-spacing": ["error", "after"],
// Deprecated, will be removed in 1.0.
"global-strict": "off",
// Only useful in a node environment.
"handle-callback-err": "off",
// Tab width.
- "indent": ["error", 2, {"SwitchCase": 1}],
+ "indent": ["error", 2, {"SwitchCase": 1, "ArrayExpression": "first", "ObjectExpression": "first"}],
// Enforces spacing between keys and values in object literal properties.
"key-spacing": ["error", {"beforeColon": false, "afterColon": true}],
// Enforces unix style line breaks.
"linebreak-style": ["error", "unix"],
// Don't enforce the maximum depth that blocks can be nested. The complexity
// rule is a better rule to check this.
"max-depth": "off",
// Maximum length of a line.
--- a/toolkit/components/extensions/.eslintrc.js
+++ b/toolkit/components/extensions/.eslintrc.js
@@ -96,17 +96,17 @@ module.exports = { // eslint-disable-lin
// Always require a trailing EOL
"eol-last": "error",
// Require function* name()
"generator-star-spacing": ["error", {"before": false, "after": true}],
// Two space indent
- "indent": ["error", 2, {"SwitchCase": 1}],
+ "indent": ["error", 2, {"SwitchCase": 1, "ArrayExpression": "first", "ObjectExpression": "first"}],
// Space after colon not before in property declarations
"key-spacing": ["error", {"beforeColon": false, "afterColon": true, "mode": "minimum"}],
// Require spaces before and after finally, catch, etc.
"keyword-spacing": "error",
// Unix linebreaks