-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy patheslint.config.js
54 lines (53 loc) · 1.21 KB
/
eslint.config.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
46
47
48
49
50
51
52
53
54
import eslintRecommended from '@eslint/js';
import importPlugin from 'eslint-plugin-import';
export default [
eslintRecommended.configs.recommended,
{
files: ['dxp/component-service/**/*.js', 'src/scripts/**/*.js'],
languageOptions: {
ecmaVersion: 2021,
sourceType: 'module',
globals: {
fetch: 'readonly',
console: 'readonly',
window: 'readonly',
document: 'readonly',
URL: 'readonly',
localStorage: 'readonly',
setTimeout: 'readonly'
}
},
settings: {
'import/resolver': {
alias: {
map: [
['@global_components', './src/global_components'],
['@dxp', './dxp'],
['@components', './dxp/component-service'],
['@styles', './src/styles']
],
extensions: ['.js', '.scss']
}
}
},
plugins: {
import: importPlugin
},
rules: {
'no-console': 'off',
semi: ['warn', 'always'],
'import/no-unresolved': 'warn'
}
},
{
ignores: [
'node_modules/',
'dist/',
'**/*.test.js',
'vite.config.js',
'*.js',
'dxp/01_compilers/*.js',
'src/entry-server.js'
]
}
];