-
Notifications
You must be signed in to change notification settings - Fork 13
/
Copy path.eslintrc.cjs
58 lines (58 loc) · 1.41 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
module.exports = {
root: true,
env: {
browser: true,
es2021: true,
},
extends: [
'eslint:recommended',
'plugin:react/recommended',
'plugin:jsonc/recommended-with-json',
'plugin:jsdoc/recommended-typescript-flavor',
'prettier',
],
parserOptions: {
ecmaFeatures: {
jsx: true,
},
ecmaVersion: 13,
sourceType: 'module',
},
overrides: [
{
files: ['**/*.json', '**/*.json5', '**/*.jsonc'],
parser: 'jsonc-eslint-parser',
},
],
plugins: ['react', 'vitest', 'jsdoc'],
settings: {
react: {
version: '18.3',
},
},
globals: {
APP_VERSION: true,
APP_ENVIRONMENT: true,
SENTRY_DSN: true,
__ANNOTATIONS_CANONICAL_BASE_URL__: true,
__BACKEND_ENDPOINT__: true,
__GRAPHQL_ENDPOINT__: true,
__PANDOC_EXPORT_ENDPOINT__: true,
},
rules: {
'jsdoc/require-description': ['off'],
'jsdoc/require-example': ['off'],
'jsdoc/require-jsdoc': ['off'],
'jsdoc/require-param-description': ['off'],
'jsdoc/require-returns-description': ['off'],
'jsdoc/require-property-description': ['off'],
'react/prop-types': 'off',
'no-unused-vars': ['warn'],
'jsonc/indent': ['error', 2],
// 'jsonc/sort-keys': ['warn'],
'jsonc/key-spacing': ['error'],
'jsonc/no-irregular-whitespace': ['error'],
'jsonc/object-curly-newline': ['error'],
'jsonc/object-property-newline': ['error'],
},
}