-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy patheslint.config.js
More file actions
38 lines (37 loc) · 1.39 KB
/
eslint.config.js
File metadata and controls
38 lines (37 loc) · 1.39 KB
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
import pluginSecurity from 'eslint-plugin-security'
import neostandard, { resolveIgnoresFromGitignore, plugins } from 'neostandard'
export default [
...neostandard({
ignores: resolveIgnoresFromGitignore(),
ts: true, // Enable TypeScript support,
filesTs: ['src/**/*.ts', '__tests__/**/*.ts']
}),
plugins.n.configs['flat/recommended-script'],
pluginSecurity.configs.recommended,
{
rules: {
'n/no-process-exit': 'warn',
'n/no-unsupported-features': 'off',
'n/no-unsupported-features/node-builtins': ['error', { ignores: ['util.styleText'] }],
'n/no-unpublished-require': 'off',
'security/detect-non-literal-fs-filename': 'off',
'security/detect-unsafe-regex': 'error',
'security/detect-buffer-noassert': 'error',
'security/detect-child-process': 'error',
'security/detect-disable-mustache-escape': 'error',
'security/detect-eval-with-expression': 'error',
'security/detect-no-csrf-before-method-override': 'error',
'security/detect-non-literal-regexp': 'error',
'security/detect-object-injection': 'warn',
'security/detect-possible-timing-attacks': 'error',
'security/detect-pseudoRandomBytes': 'error',
'space-before-function-paren': 'off',
'object-curly-spacing': 'off',
'n/hashbang': 'off'
},
languageOptions: {
ecmaVersion: 2024,
sourceType: 'module',
},
},
]