-
Notifications
You must be signed in to change notification settings - Fork 56
Expand file tree
/
Copy patheslint.config.js
More file actions
45 lines (44 loc) · 1.05 KB
/
eslint.config.js
File metadata and controls
45 lines (44 loc) · 1.05 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
39
40
41
42
43
44
45
/* eslint-disable @typescript-eslint/no-require-imports */
const { defineConfig } = require('eslint/config');
const fecPlugin = require('@redhat-cloud-services/eslint-config-redhat-cloud-services');
const tsParser = require('@typescript-eslint/parser');
const tseslint = require('typescript-eslint');
module.exports = defineConfig(
fecPlugin,
{
languageOptions: {
globals: {
insights: 'readonly',
},
},
ignores: ['node_modules/*', 'dist/*'],
rules: {
requireConfigFile: 'off',
'sort-imports': [
'error',
{
ignoreDeclarationSort: true,
},
],
},
},
tseslint.configs.recommended,
{
files: ['src/**/*.ts', 'src/**/*.tsx'],
languageOptions: {
parser: tsParser,
},
rules: {
'react/prop-types': 'off',
'@typescript-eslint/no-unused-vars': 'error',
},
},
{
files: ['cypress/**/*.ts', 'cypress/**/*.tsx'],
parser: '@typescript-eslint/parser',
plugins: ['jest'],
rules: {
'jest/expect-expect': 'off',
},
},
);