feat(eslint): Rule "indent"

Signed-off-by: Valentin Popov <info@valentineus.link>
This commit is contained in:
Valentin Popov 2020-02-13 15:03:51 +04:00
parent 6beddfac34
commit fe5de6953a
Signed by: Valentin Popov
GPG Key ID: 269A00ACA90A8EA3
2 changed files with 28 additions and 1 deletions

View File

@ -50,7 +50,7 @@
- [ ] "id-length" - [ ] "id-length"
- [ ] "id-match" - [ ] "id-match"
- [ ] "implicit-arrow-linebreak" - [ ] "implicit-arrow-linebreak"
- [ ] "indent" - [X] "indent"
- [X] "indent-legacy" - [X] "indent-legacy"
- [ ] "init-declarations" - [ ] "init-declarations"
- [ ] "jsx-quotes" - [ ] "jsx-quotes"

View File

@ -3,6 +3,33 @@
"error", "error",
"always" "always"
], ],
"indent": [
"error",
"tab",
{
"ArrayExpression": 1,
"CallExpression": {
"arguments": 1
},
"FunctionDeclaration": {
"body": 1,
"parameters": 1
},
"FunctionExpression": {
"body": 1,
"parameters": 1
},
"ImportDeclaration": 1,
"MemberExpression": 1,
"ObjectExpression": 1,
"SwitchCase": 1,
"VariableDeclarator": "first",
"flatTernaryExpressions": true,
"ignoreComments": false,
"ignoredNodes": [],
"outerIIFEBody": 1
}
],
"indent-legacy": [ "indent-legacy": [
"off" "off"
], ],