forked from elastic/kibana
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.js
45 lines (42 loc) · 1.01 KB
/
.eslintrc.js
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
module.exports = {
extends: [
'@elastic/eslint-config-kibana',
'@elastic/eslint-config-kibana/jest',
],
settings: {
'import/resolver': {
'@elastic/eslint-import-resolver-kibana': {
rootPackageName: 'kibana',
kibanaPath: '.',
},
},
},
overrides: [
// Enable Prettier
{
files: [
'.eslintrc.js',
'packages/kbn-pm/**/*',
'packages/kbn-datemath/**/*.js',
'packages/kbn-plugin-generator/**/*',
],
plugins: ['prettier'],
rules: Object.assign(
{ 'prettier/prettier': 'error' },
require('eslint-config-prettier').rules,
require('eslint-config-prettier/react').rules
),
},
// files not transpiled by babel can't using things like object-spread
{
files: [
'.eslintrc.js',
'packages/kbn-plugin-helpers/**/*',
'packages/kbn-plugin-generator/**/*',
],
rules: {
'prefer-object-spread/prefer-object-spread': 'off',
},
},
],
};