-
-
Notifications
You must be signed in to change notification settings - Fork 28
/
.eslintrc.cjs
67 lines (67 loc) · 1.96 KB
/
.eslintrc.cjs
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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
/**
* @type { import('eslint').ESLint.ConfigData }
*/
module.exports = {
extends: ['standard-with-typescript', 'prettier'],
parser: '@typescript-eslint/parser',
plugins: ['@typescript-eslint', 'eslint-plugin-tsdoc'],
ignorePatterns: [
'pkg',
'github',
'vscode',
'analysis',
'analysis_strings',
'i18n',
'markdown',
'node_modules',
'roll20',
'./*.*',
'src/adapter',
'src/data-legacy',
'src/extras',
'src/templates',
'json-typedef',
'.eslintrc.js',
'*.d.ts',
'*.json',
'*.cjs'
],
parserOptions: {
tsconfigRootDir: __dirname,
project: './tsconfig.json',
ecmaVersion: 'latest'
// supposedly this is faster: https://typescript-eslint.io/packages/parser/#experimental_useprojectservice
// EXPERIMENTAL_useProjectService: true
},
rules: {
'@typescript-eslint/class-literal-property-style': 'off',
'@typescript-eslint/prefer-readonly': 'error',
'@typescript-eslint/array-type': 'off',
'@typescript-eslint/no-redeclare': 'off',
// Pretty fraught since there's a few of them in use. Maybe possible to define, but i'm not sure it's worth the effort right now.
'@typescript-eslint/naming-convention': 'off',
'@typescript-eslint/consistent-type-assertions': 'off',
// 'tsdoc/syntax': 'warn',
'@typescript-eslint/key-spacing': 'off',
'@typescript-eslint/no-empty-interface': 'off',
'@typescript-eslint/consistent-type-definitions': 'off',
'@typescript-eslint/consistent-type-imports': [
'error',
{ prefer: 'type-imports', fixStyle: 'inline-type-imports' }
],
'@typescript-eslint/explicit-function-return-type': 'off',
'@typescript-eslint/strict-boolean-expressions': 'off',
'@typescript-eslint/ban-ts-comment': 'off',
'@typescript-eslint/no-namespace': 'off',
'@typescript-eslint/return-await': 'off',
'@typescript-eslint/method-signature-style': 'off',
'@typescript-eslint/no-unused-vars': [
'warn',
{
varsIgnorePattern: '^_',
destructuredArrayIgnorePattern: '^_',
ignoreRestSiblings: true
}
]
}
}