1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53
| module.exports = { env: { node: true, es6: true, jest: true }, extends: [ 'airbnb-base', 'plugin:security/recommended' ], plugins: [ 'security', 'import' ], rules: { 'no-await-in-loop': 'warn', 'require-atomic-updates': 'error',
'security/detect-non-literal-fs-filename': 'warn', 'security/detect-buffer-noassert': 'error', 'security/detect-child-process': 'warn', 'security/detect-disable-mustache-escape': 'error', 'security/detect-eval-with-expression': 'error', 'security/detect-new-buffer': 'error', 'security/detect-no-csrf-before-method-override': 'error', 'security/detect-non-literal-regexp': 'warn', 'security/detect-object-injection': 'warn', 'security/detect-possible-timing-attacks': 'warn', 'security/detect-pseudoRandomBytes': 'error', 'security/detect-unsafe-regex': 'error',
'max-lines-per-function': ['warn', { max: 50, skipBlankLines: true, skipComments: true }], 'complexity': ['warn', 10], 'max-depth': ['warn', 4], 'max-nested-callbacks': ['warn', 3], 'prefer-template': 'error', 'no-var': 'error', 'prefer-const': 'error' }, overrides: [ { files: ['*.test.js', '*.spec.js'], rules: { 'security/detect-non-literal-fs-filename': 'off', 'no-unused-expressions': 'off' } } ] };
|