remove unnecessary rules

This commit is contained in:
Timo Hocker 2019-12-20 09:38:16 +01:00
parent 3085995ff4
commit be612e8aaf

View File

@ -17,7 +17,6 @@ module.exports = {
'valid-typeof': ['error', { requireStringLiterals: true }], 'valid-typeof': ['error', { requireStringLiterals: true }],
// Best Practices https://eslint.org/docs/rules/#best-practices // Best Practices https://eslint.org/docs/rules/#best-practices
'accessor-pairs': 'off',
'array-callback-return': ['error', { allowImplicit: false }], 'array-callback-return': ['error', { allowImplicit: false }],
'block-scoped-var': 'error', 'block-scoped-var': 'error',
'class-methods-use-this': 'error', 'class-methods-use-this': 'error',
@ -50,7 +49,6 @@ module.exports = {
'no-implied-eval': 'error', 'no-implied-eval': 'error',
'no-invalid-this': 'error', 'no-invalid-this': 'error',
'no-iterator': 'error', 'no-iterator': 'error',
'no-labels': 'off',
'no-lone-blocks': 'error', 'no-lone-blocks': 'error',
'no-loop-func': 'error', 'no-loop-func': 'error',
'no-magic-numbers': ['error', { enforceConst: true, ignoreArrayIndexes: true, detectObjects: false }], 'no-magic-numbers': ['error', { enforceConst: true, ignoreArrayIndexes: true, detectObjects: false }],
@ -92,7 +90,6 @@ module.exports = {
// Variables https://eslint.org/docs/rules/#variables // Variables https://eslint.org/docs/rules/#variables
'init-declarations': ['error', 'always'], 'init-declarations': ['error', 'always'],
'no-label-var': 'error', 'no-label-var': 'error',
'no-restricted-globals': 'off',
'no-shadow': ['error', { builtinGlobals: true, hoist: 'all' }], 'no-shadow': ['error', { builtinGlobals: true, hoist: 'all' }],
'no-undef-init': 'error', 'no-undef-init': 'error',
'no-undefined': 'error', 'no-undefined': 'error',
@ -108,7 +105,6 @@ module.exports = {
'no-path-concat': 'error', 'no-path-concat': 'error',
'no-process-env': 'warn', 'no-process-env': 'warn',
'no-process-exit': 'warn', 'no-process-exit': 'warn',
'no-restricted-modules': 'off',
'no-sync': ['error', { allowAtRootLevel: true }], 'no-sync': ['error', { allowAtRootLevel: true }],
// Stylistic Issues https://eslint.org/docs/rules/#stylistic-issues // Stylistic Issues https://eslint.org/docs/rules/#stylistic-issues
@ -118,7 +114,6 @@ module.exports = {
'block-spacing': ['error', 'always'], 'block-spacing': ['error', 'always'],
'brace-style': ['error', 'stroustrup', { allowSingleLine: true }], 'brace-style': ['error', 'stroustrup', { allowSingleLine: true }],
camelcase: 'error', camelcase: 'error',
'capitalized-comments': 'off',
'comma-dangle': ['error', 'never'], 'comma-dangle': ['error', 'never'],
'comma-spacing': 'error', 'comma-spacing': 'error',
'comma-style': 'error', 'comma-style': 'error',
@ -131,8 +126,6 @@ module.exports = {
'func-style': ['error', 'declaration', { allowArrowFunctions: false }], 'func-style': ['error', 'declaration', { allowArrowFunctions: false }],
'function-call-argument-newline': ['error', 'consistent'], 'function-call-argument-newline': ['error', 'consistent'],
'function-paren-newline': ['error', 'multiline-arguments'], 'function-paren-newline': ['error', 'multiline-arguments'],
'id-blacklist': 'off',
'id-length': 'off',
'id-match': ['error', '^([nsoa]([A-Z][a-z]+)+|[a-z])$'], 'id-match': ['error', '^([nsoa]([A-Z][a-z]+)+|[a-z])$'],
'implicit-arrow-linebreak': ['error', 'beside'], 'implicit-arrow-linebreak': ['error', 'beside'],
indent: ['error', 2], indent: ['error', 2],
@ -173,17 +166,24 @@ module.exports = {
'always', 'always',
{ exceptAftersingleLine: true } { exceptAftersingleLine: true }
], ],
'max-depth': ['error', 4], 'max-depth': ['warn', 4],
'max-len': ['error', { code: 80, tabWidth: 4 }], 'max-len': ['warn', { code: 80, tabWidth: 4 }],
'max-lines': [ 'max-lines': [
'error', 'warn',
{ {
max: 300, max: 300,
skipBlankLines: true, skipBlankLines: true,
ignoreComments: true ignoreComments: true
} }
], ],
'max-lines-per-function': null, // https://eslint.org/docs/rules/max-lines-per-function // enforce a maximum number of line of code in a function 'max-lines-per-function': [
'warn',
{
max: 50,
skipBlankLines: true,
skipComments: true,
IIFEs: true
}],
'max-nested-callbacks': null, // https://eslint.org/docs/rules/max-nested-callbacks // enforce a maximum depth that callbacks can be nested 'max-nested-callbacks': null, // https://eslint.org/docs/rules/max-nested-callbacks // enforce a maximum depth that callbacks can be nested
'max-params': null, // https://eslint.org/docs/rules/max-params // enforce a maximum number of parameters in function definitions 'max-params': null, // https://eslint.org/docs/rules/max-params // enforce a maximum number of parameters in function definitions
'max-statements': null, // https://eslint.org/docs/rules/max-statements // enforce a maximum number of statements allowed in function blocks 'max-statements': null, // https://eslint.org/docs/rules/max-statements // enforce a maximum number of statements allowed in function blocks