-
Notifications
You must be signed in to change notification settings - Fork 3
/
eslint.config.mjs
66 lines (60 loc) · 1.69 KB
/
eslint.config.mjs
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
59
60
61
62
63
64
65
66
import js from '@eslint/js'
import neostandard from 'neostandard'
import pluginVue from 'eslint-plugin-vue'
import vueParser from 'vue-eslint-parser'
import { FlatCompat } from '@eslint/eslintrc'
const compat = new FlatCompat()
export default [
js.configs.recommended,
...pluginVue.configs['flat/essential'],
...neostandard(),
...compat.extends(
'plugin:vue-pug/vue3-recommended'
),
{
ignores: [
'/dist',
'/src-capacitor',
'/src-cordova',
'/.quasar',
'/node_modules'
],
languageOptions: {
ecmaVersion: 'latest',
sourceType: 'module',
parser: vueParser,
globals: {
__statics: 'readonly',
__QUASAR_SSR__: 'readonly',
__QUASAR_SSR_SERVER__: 'readonly',
__QUASAR_SSR_CLIENT__: 'readonly',
__QUASAR_SSR_PWA__: 'readonly',
process: 'readonly',
Capacitor: 'readonly',
chrome: 'readonly',
EVENT_BUS: 'readonly'
}
},
rules: {
// allow async-await
'generator-star-spacing': 'off',
// allow paren-less arrow functions
'arrow-parens': 'off',
'one-var': 'off',
'no-void': 'off',
'multiline-ternary': 'off',
// 'import/first': 'off',
// 'import/named': 'error',
// 'import/namespace': 'error',
// 'import/default': 'error',
// 'import/export': 'error',
// 'import/extensions': 'off',
// 'import/no-unresolved': 'off',
// 'import/no-extraneous-dependencies': 'off',
'prefer-promise-reject-errors': 'off',
// allow debugger during development only
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off'
// 'no-unused-vars': 'off'
}
}
]