forked from ieskudero/three-dxf-viewer
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy patheslint.config.js
52 lines (51 loc) · 1.2 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
import globals from 'globals';
import js from '@eslint/js';
import babelParser from '@babel/eslint-parser';
import react from 'eslint-plugin-react';
export default [
{
ignores: [
'dist/*',
'api/*',
'node_modules/*',
'.npm/*',
'**/package-lock.json',
'**/jsdoc.js',
'**/vite.prod.config.js'
]
},
js.configs.recommended,
{
languageOptions: {
ecmaVersion: 2022,
sourceType: 'module',
globals: {
...globals.browser,
myCustomGlobal: 'readonly'
},
parser: babelParser,
parserOptions: {
requireConfigFile: false,
babelOptions: {
presets: [ '@babel/preset-react' ]
}
}
},
plugins : {
react: react
},
rules: {
'indent': [ 'error', 'tab' ],
'linebreak-style': [ 'error', 'windows' ],
'quotes': [ 'error', 'single' ],
'semi': [ 'error', 'always' ],
'no-async-promise-executor': 'off',
'space-in-parens': [ 'error', 'always' ],
'object-curly-spacing': [ 'error', 'always' ],
'array-bracket-spacing': [ 'error', 'always' ],
'react/jsx-uses-react': 'error',
'react/jsx-uses-vars': 'error'
},
files: [ 'src/**/*.js', 'src/**/*.jsx','example/**/*.js', 'example/**/*.jsx' ]
}
];