mirror of
https://github.com/zrgn/zrgn.github.io
synced 2024-12-24 23:56:34 +00:00
Add eslint settings file.
This commit is contained in:
parent
f8e085c354
commit
9c285bc936
1 changed files with 105 additions and 0 deletions
105
.eslintrc.json
Normal file
105
.eslintrc.json
Normal file
|
@ -0,0 +1,105 @@
|
|||
{
|
||||
"env": {
|
||||
"node": true,
|
||||
"jest": true
|
||||
},
|
||||
"extends": "eslint:recommended",
|
||||
"parserOptions": {
|
||||
"ecmaVersion": 6
|
||||
},
|
||||
"rules": {
|
||||
"array-bracket-spacing": [
|
||||
"error",
|
||||
"always"
|
||||
],
|
||||
"block-scoped-var": "error",
|
||||
"block-spacing": [
|
||||
"error",
|
||||
"never"
|
||||
],
|
||||
"brace-style": [
|
||||
"error",
|
||||
"1tbs"
|
||||
],
|
||||
"comma-dangle": [
|
||||
"error",
|
||||
"never"
|
||||
],
|
||||
"indent": [
|
||||
"error",
|
||||
4
|
||||
],
|
||||
"linebreak-style": [
|
||||
"error",
|
||||
"unix"
|
||||
],
|
||||
"global-require": "error",
|
||||
"no-extra-parens": "error",
|
||||
"no-inline-comments": "error",
|
||||
"no-lonely-if": "error",
|
||||
"no-multiple-empty-lines": [
|
||||
"error",
|
||||
{
|
||||
"max": 1,
|
||||
"maxBOF": 0,
|
||||
"maxEOF": 0
|
||||
}
|
||||
],
|
||||
"no-mixed-operators": "error",
|
||||
"no-mixed-requires": "error",
|
||||
"no-nested-ternary": "error",
|
||||
"no-plusplus": "error",
|
||||
"no-return-assign": "error",
|
||||
"no-trailing-spaces": "error",
|
||||
"no-useless-return": "error",
|
||||
"object-curly-newline": [
|
||||
"error",
|
||||
{
|
||||
"minProperties": 2
|
||||
}
|
||||
],
|
||||
"one-var": [
|
||||
"error",
|
||||
{
|
||||
"initialized": "never",
|
||||
"uninitialized": "consecutive"
|
||||
}
|
||||
],
|
||||
"one-var-declaration-per-line": [
|
||||
"error",
|
||||
"initializations"
|
||||
],
|
||||
"padded-blocks": [
|
||||
"error",
|
||||
"never"
|
||||
],
|
||||
"quotes": [
|
||||
"error",
|
||||
"single"
|
||||
],
|
||||
"require-jsdoc": [
|
||||
"warn",
|
||||
{
|
||||
"require": {
|
||||
"FunctionDeclaration": true,
|
||||
"MethodDefinition": true,
|
||||
"ClassDeclaration": true,
|
||||
"ArrowFunctionExpression": true,
|
||||
"FunctionExpression": true
|
||||
}
|
||||
}
|
||||
],
|
||||
"semi": [
|
||||
"error",
|
||||
"always"
|
||||
],
|
||||
"space-before-function-paren": [
|
||||
"error",
|
||||
{
|
||||
"anonymous": "always",
|
||||
"named": "never"
|
||||
}
|
||||
],
|
||||
"valid-jsdoc": "error"
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue