-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy patheslint.config.js
47 lines (46 loc) · 1.61 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
import js from '@eslint/js';
import globals from 'globals';
import tsParser from '@typescript-eslint/parser';
import tsPlugin from '@typescript-eslint/eslint-plugin';
import vueParser from 'vue-eslint-parser';
import vuePlugin from 'eslint-plugin-vue';
import prettier from 'eslint-config-prettier';
import prettierPlugin from 'eslint-plugin-prettier';
export default [
js.configs.recommended,
{
files: ['**/*.{js,jsx,ts,tsx,vue}'],
languageOptions: {
ecmaVersion: 2021,
sourceType: 'module',
parser: vueParser,
parserOptions: {
parser: tsParser,
extraFileExtensions: ['.vue']
},
globals: {
...globals.browser,
...globals.es2021,
...globals.node,
ImportMetaEnv: 'readonly'
}
},
plugins: {
'@typescript-eslint': tsPlugin,
vue: vuePlugin,
'eslint-plugin-prettier': prettierPlugin,
'eslint-config-prettier': prettier
},
rules: {
'vue/multi-word-component-names': 'off',
'vue/no-multiple-template-root': 'off',
'@typescript-eslint/no-explicit-any': 'off',
'@typescript-eslint/no-non-null-assertion': 'off',
'no-console': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
'no-debugger': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
'no-unused-vars': 'off',
'@typescript-eslint/no-unused-vars': 'off',
'no-useless-catch': 'off'
}
}
];